Skip to content

Conversation

gotalab
Copy link

@gotalab gotalab commented Sep 3, 2025

Summary

  • Adds --specs-dir to specify init and saves it to git config (spec-kit.specsDir).
  • Scripts resolve the specs base directory from git config; default remains specs/.

Motivation

  • Make it easier to align with project documentation structures (e.g., docs/specs) while keeping backwards compatibility.

Changes

  • src/specify_cli/init.py: add --specs-dir to init; persist to git config when repo exists.
  • scripts/common.sh: get_feature_dir() reads spec-kit.specsDir (fallback to specs).
  • scripts/update-agent-context.sh: FEATURE_DIR resolves via spec-kit.specsDir.
  • scripts/create-new-feature.sh: SPECS_DIR resolves via spec-kit.specsDir.
  • README.md: minimal usage examples and optional post-copy note.

Usage

Compatibility

  • No breaking changes; defaults to specs/ if unset.

Testing

  • Verified end-to-end with the Spec-Driven Development workflow on Claude Code, Gemini CLI and GitHub Copilot
  • To test script functionality, the following command executed:
uvx --from path/to/spec-kit/ specify init --here --specs-dir docs/specs \
&& rsync -a --delete path/to/spec-kit/scripts/ ./scripts/ \
&& chmod +x ./scripts/*.sh

@gotalab gotalab requested a review from localden as a code owner September 3, 2025 19:55
@peterHoburg
Copy link

peterHoburg commented Sep 7, 2025

IMO it should be .speckit . Many tools are using . dirs now.
.claude .cursor .github .venv .agent-os etc...

Related to #38

@mkellerman
Copy link

Please see my implementation here: #86

@gotalab
Copy link
Author

gotalab commented Sep 9, 2025

I agree. .speckit feels consistent with the other tools.
Close this PR.

@gotalab gotalab closed this Sep 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants