Bug Description
When following the upgrade guide and running:
specify init --here --force --ai copilot
...the CLI does NOT update any existing files under .specify/scripts/ or .specify/templates/, even if there are newer versions of scripts/templates available. Only missing files are added. This contradicts the upgrade documentation, which instructs users to use init as the mechanism to update project files after an upgrade.
This leads to users being stuck on old scripts and templates, without an obvious way to safely receive updates from new releases unless they manually delete/replace directories.
Steps to Reproduce
-
Install/upgrade to specify-cli 0.7.4 (latest)
-
In a project with existing .specify/scripts/ and/or .specify/templates/, run:
specify init --here --force --ai copilot
-
Observe that files in those folders are not changed (no updates from the latest release)
-
Compare contents of .specify/scripts/ or .specify/templates/ to a newly created project (or reference repo) and see that old files remained.
Expected Behavior
Running the upgrade instructions (specify init --here --force --ai copilot) should update all managed/shared infrastructure files to the latest version—including all .specify/scripts and .specify/templates files, so projects receive improvements and fixes in those scripts and templates after upgrading Spec Kit. At the least, the docs should reflect what will (and won't) update, and provide a migration path for shared infra.
Actual Behavior
Existing files in .specify/scripts/ and .specify/templates/ are not overwritten or updated—no matter what. Only new (missing) files are added, and existing ones are skipped.
There is no CLI flag or documented mechanism to force a refresh of those files (without manual deletion). The upgrade documentation does not warn users about this, leading to confusion and missed bugfixes or features that are distributed via shared scripts/templates.
Specify CLI Version
0.7.4
AI Agent
GitHub Copilot
Operating System
Linux
Python Version
3.12.3
Error Logs
Additional Context
Root cause: The _install_shared_infra() function (used by init) explicitly skips copying over any script or template file if it already exists, regardless of the --force flag. Only missing files are installed. See src/specify_cli/__init__.py.
This means users cannot receive upstream fixes, enhancements, or bugfixes to shared scripts or templates after their first project initialization (unless they delete those folders/files manually). The specify integration upgrade command also does not update shared infra, only integration-managed files.
Suggestion:
- Either:
- Document the current behavior clearly and provide users a safe refresh workaround
- Or, provide a new CLI flag (e.g.,
--force-shared or --overwrite-shared-infra) to allow overwriting shared scripts/templates on upgrade/init
- Optionally, add a warning during init/upgrade when skipping out-of-date files so users know they missed an update
Reference: see conversation and analysis in issue creation
Bug Description
When following the upgrade guide and running:
...the CLI does NOT update any existing files under
.specify/scripts/or.specify/templates/, even if there are newer versions of scripts/templates available. Only missing files are added. This contradicts the upgrade documentation, which instructs users to use init as the mechanism to update project files after an upgrade.This leads to users being stuck on old scripts and templates, without an obvious way to safely receive updates from new releases unless they manually delete/replace directories.
Steps to Reproduce
Install/upgrade to specify-cli 0.7.4 (latest)
In a project with existing
.specify/scripts/and/or.specify/templates/, run:specify init --here --force --ai copilot
Observe that files in those folders are not changed (no updates from the latest release)
Compare contents of
.specify/scripts/or.specify/templates/to a newly created project (or reference repo) and see that old files remained.Expected Behavior
Running the upgrade instructions (
specify init --here --force --ai copilot) should update all managed/shared infrastructure files to the latest version—including all.specify/scriptsand.specify/templatesfiles, so projects receive improvements and fixes in those scripts and templates after upgrading Spec Kit. At the least, the docs should reflect what will (and won't) update, and provide a migration path for shared infra.Actual Behavior
Existing files in
.specify/scripts/and.specify/templates/are not overwritten or updated—no matter what. Only new (missing) files are added, and existing ones are skipped.There is no CLI flag or documented mechanism to force a refresh of those files (without manual deletion). The upgrade documentation does not warn users about this, leading to confusion and missed bugfixes or features that are distributed via shared scripts/templates.
Specify CLI Version
0.7.4
AI Agent
GitHub Copilot
Operating System
Linux
Python Version
3.12.3
Error Logs
Additional Context
Root cause: The
_install_shared_infra()function (used byinit) explicitly skips copying over any script or template file if it already exists, regardless of the--forceflag. Only missing files are installed. Seesrc/specify_cli/__init__.py.This means users cannot receive upstream fixes, enhancements, or bugfixes to shared scripts or templates after their first project initialization (unless they delete those folders/files manually). The
specify integration upgradecommand also does not update shared infra, only integration-managed files.Suggestion:
--force-sharedor--overwrite-shared-infra) to allow overwriting shared scripts/templates on upgrade/initReference: see conversation and analysis in issue creation