Skip to content

Commit 1266de9

Browse files
authored
fix(shiny create): Use template.id for default directory (#1666)
1 parent 18d6ac8 commit 1266de9

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to Shiny for Python will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [UNRELEASED]
9+
10+
### Bug fixes
11+
12+
* `shiny create` now uses the template `id` rather than the directory name as the default directory. (#1666)
13+
814
## [1.1.0] - 2024-09-03
915

1016
### New features

shiny/_main_create.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -657,7 +657,6 @@ def app_template_questions(
657657
mode: Optional[str] = None,
658658
dest_dir: Optional[Path] = None,
659659
):
660-
template_dir = template.path
661660
template_cli_name = cli_bold(cli_field(template.title or template.id))
662661

663662
if mode == "express" and not template.express_available:
@@ -666,7 +665,7 @@ def app_template_questions(
666665
)
667666

668667
click.echo(cli_wait(f"Creating {template_cli_name} Shiny app..."))
669-
dest_dir = directory_prompt(dest_dir, template_dir.name)
668+
dest_dir = directory_prompt(dest_dir, template.id)
670669

671670
if mode is None and template.express_available:
672671
mode = questionary.select(

0 commit comments

Comments
 (0)