[go: up one dir, main page]

Skip to content

Commit

Permalink
Merge branch '0.2.x' into issue-93-use-same-template-version-in-links
Browse files Browse the repository at this point in the history
  • Loading branch information
albamig committed Mar 16, 2022
2 parents 8732687 + e94a83a commit 3a17fad
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions minos/cli/api/new.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ def new_microservice(name: str) -> None:
processor = TemplateProcessor.from_fetcher(fetcher, microservice_path, defaults={"name": name})
processor.render()

(microservice_path / ".build_docker_compose.txt").unlink()


@app.callback()
def callback():
Expand Down
2 changes: 1 addition & 1 deletion minos/cli/templating/fetchers.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
)

TEMPLATE_URL: Final[str] = "https://github.com/minos-framework/minos-templates/releases/download"
TEMPLATE_VERSION: Final[str] = "v0.1.2.dev4"
TEMPLATE_VERSION: Final[str] = "v0.1.2.dev6"


class TemplateFetcher:
Expand Down
2 changes: 2 additions & 0 deletions tests/test_cli/test_api/test_new.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ def test_new_project(self) -> None:
def test_new_microservice(self) -> None:
with TemporaryDirectory() as tmp_dir_name:
path = Path(tmp_dir_name) / "product"
path.mkdir()
(path / ".build_docker_compose.txt").touch()
with patch("minos.cli.TemplateProcessor.render") as mock:
result = CliRunner().invoke(app, ["new", "microservice", str(path)])

Expand Down

0 comments on commit 3a17fad

Please sign in to comment.