Skip to content

Commit 3e91df4

Browse files
committed
Update tutorials to always have a name
1 parent 8112701 commit 3e91df4

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

docs_src/subcommands/name_help/tutorial002.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
app = typer.Typer()
44

55
users_app = typer.Typer()
6-
app.add_typer(users_app)
6+
app.add_typer(users_app, name="users")
77

88

99
@users_app.callback()

docs_src/subcommands/name_help/tutorial003.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ def users():
99
"""
1010

1111

12-
users_app = typer.Typer(callback=users)
12+
users_app = typer.Typer(callback=users, name="users")
1313
app.add_typer(users_app)
1414

1515

docs_src/subcommands/name_help/tutorial004.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def old_callback():
1010

1111

1212
users_app = typer.Typer(callback=old_callback)
13-
app.add_typer(users_app)
13+
app.add_typer(users_app, name="users")
1414

1515

1616
@users_app.callback()

docs_src/subcommands/name_help/tutorial005.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ def old_callback():
99
"""
1010

1111

12-
users_app = typer.Typer(callback=old_callback)
12+
users_app = typer.Typer(callback=old_callback, name="users")
1313

1414

1515
def new_users():
@@ -18,7 +18,7 @@ def new_users():
1818
"""
1919

2020

21-
app.add_typer(users_app, callback=new_users)
21+
app.add_typer(users_app, callback=new_users, name="new-users")
2222

2323

2424
@users_app.callback()

0 commit comments

Comments
 (0)