Hello team,
I've been using Spec Kit and find the concept of executable specifications very powerful. However, I'd like to suggest an enhancement to the underlying script execution mechanism.
Currently, Spec Kit uses separate Bash and PowerShell scripts for various automation tasks (e.g., check-task-prerequisites.sh, create-new-feature.sh). This approach requires users to choose their OS-specific scripts and maintain two parallel codebases, which can lead to:
- Maintenance overhead: Changes need to be made in two places.
- Divergence risk: Scripts might become out of sync.
- Platform lock-in: Users need specific shell environments.
- Complexity: Managing cross-platform differences in shell scripting can be tricky.
I propose consolidating these scripts into a single Python-based CLI tool. This approach offers several advantages:
- Leverages Existing Dependency: Spec Kit is already a uv tool, meaning Python and uv are already prerequisites. This change would not introduce new mandatory dependencies for users who already have Spec Kit installed.
- Cross-Platform Compatibility: A well-written Python script can run seamlessly on Windows, macOS, and Linux without needing separate Bash/PowerShell variants.
- Consistent Behavior: Eliminates potential differences arising from shell-specific quirks.
- Simplified Maintenance: Only one codebase for the helper scripts.
uv run Pinning: Scripts can utilize uv's "script pinning" feature (using shebangs like # /// script or #! with uv run) to manage specific Python dependencies directly within the script file, ensuring reproducible execution environments.
For example, instead of:
bash scripts/create-new-feature.sh <feature_name>
or
pwsh scripts/create-new-feature.ps1 <feature_name>
It could become:
uv run scripts/create_new_feature.py <feature_name>
or potentially a command within the main specify CLI tool itself (e.g., specify run create-feature <feature_name>).
This idea builds upon the goal of streamlining the tooling, similar to the discussion in #280 (regarding a Bun/Node.js CLI). However, utilizing Python with uv run pinning could achieve the desired consolidation without requiring users to install Node.js/Bun as an additional dependency, making it potentially more accessible for those already using Spec Kit within a Python environment.
Are you open to exploring a Python-based consolidation for the helper scripts? I believe it could simplify the user experience and improve maintainability.
Thank you for considering this feedback!
Hello team,
I've been using Spec Kit and find the concept of executable specifications very powerful. However, I'd like to suggest an enhancement to the underlying script execution mechanism.
Currently, Spec Kit uses separate Bash and PowerShell scripts for various automation tasks (e.g.,
check-task-prerequisites.sh,create-new-feature.sh). This approach requires users to choose their OS-specific scripts and maintain two parallel codebases, which can lead to:I propose consolidating these scripts into a single Python-based CLI tool. This approach offers several advantages:
uv runPinning: Scripts can utilize uv's "script pinning" feature (using shebangs like# /// scriptor#!withuv run) to manage specific Python dependencies directly within the script file, ensuring reproducible execution environments.For example, instead of:
bash scripts/create-new-feature.sh <feature_name>or
pwsh scripts/create-new-feature.ps1 <feature_name>It could become:
uv run scripts/create_new_feature.py <feature_name>or potentially a command within the main specify CLI tool itself (e.g.,
specify run create-feature <feature_name>).This idea builds upon the goal of streamlining the tooling, similar to the discussion in #280 (regarding a Bun/Node.js CLI). However, utilizing Python with uv run pinning could achieve the desired consolidation without requiring users to install Node.js/Bun as an additional dependency, making it potentially more accessible for those already using Spec Kit within a Python environment.
Are you open to exploring a Python-based consolidation for the helper scripts? I believe it could simplify the user experience and improve maintainability.
Thank you for considering this feedback!