Skip to content

Commit 9c6ba0b

Browse files
authored
Set default tag value to main. (Fixes #15) (#16)
1 parent da46da4 commit 9c6ba0b

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

cookieplone/cli.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def cli(
5353
data.OptionalPath,
5454
typer.Option("--output-dir", "-o", help="Where to generate the code."),
5555
] = None,
56-
tag: Annotated[str, typer.Option(help="Tag.")] = "",
56+
tag: Annotated[str, typer.Option(help="Tag.")] = "main",
5757
version: Annotated[
5858
bool, typer.Option("--version", help="Display the version of cookieplone.")
5959
] = False,

cookieplone/generator.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ def generate(
8787
Context: {context_str}
8888
"""
8989
raise GeneratorException(message=msg, original=undefined_err) # noQA:B904
90+
except Exception as e:
91+
raise GeneratorException(message=str(e), original=e) # noQA:B904
9092
else:
9193
return Path(result)
9294

news/15.bugfix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Set default `tag` value to **main** instead of the empty string [@ericof]

0 commit comments

Comments
 (0)