Skip to content

Commit 9e875ad

Browse files
authored
feat(poly create proejct): quiet option does not trigger interactive mode (#443)
* fix(poly create project): quiet option will not trigger interactive mode * bump Poetry plugin to 1.52.0 * bump CLI to 1.46.0
1 parent f7d2353 commit 9e875ad

4 files changed

Lines changed: 9 additions & 4 deletions

File tree

bases/polylith/cli/create.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
from polylith import interactive, project
44
from polylith.bricks import base, component
5+
from polylith.cli import options
56
from polylith.commands.create import create
67
from polylith.workspace.create import create_workspace
78
from typer import Exit, Option, Typer
@@ -57,11 +58,13 @@ def _create_project(root: Path, options: dict):
5758
def project_command(
5859
name: Annotated[str, Option(help="Name of the project.")],
5960
description: Annotated[str, Option(help="Description of the project.")] = "",
61+
quiet: Annotated[bool, options.quiet] = False,
6062
):
6163
"""Creates a Polylith project."""
6264
create(name, description, _create_project)
6365

64-
interactive.project.run(name)
66+
if not quiet:
67+
interactive.project.run(name)
6568

6669

6770
@app.command("workspace")

components/polylith/poetry/commands/create_project.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,11 @@ class CreateProjectCommand(Command):
3434
def handle(self) -> int:
3535
name = self.option("name")
3636
description = self.option("description")
37+
quiet = self.option("quiet")
3738

3839
create(name, description, create_project)
3940

40-
interactive.project.run(name)
41+
if not quiet:
42+
interactive.project.run(name)
4143

4244
return 0

projects/poetry_polylith_plugin/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "poetry-polylith-plugin"
3-
version = "1.51.3"
3+
version = "1.52.0"
44
description = "A Poetry plugin that adds tooling support for the Polylith Architecture"
55
authors = ["David Vujic"]
66
homepage = "https://davidvujic.github.io/python-polylith-docs/"

projects/polylith_cli/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "polylith-cli"
3-
version = "1.45.3"
3+
version = "1.46.0"
44
description = "Python tooling support for the Polylith Architecture"
55
authors = ['David Vujic']
66
homepage = "https://davidvujic.github.io/python-polylith-docs/"

0 commit comments

Comments
 (0)