Skip to content

docs(installation): document the 'py' (Python) script type#3640

Merged
mnriem merged 2 commits into
github:mainfrom
jawwad-ali:docs/installation-py-script-type
Jul 22, 2026
Merged

docs(installation): document the 'py' (Python) script type#3640
mnriem merged 2 commits into
github:mainfrom
jawwad-ali:docs/installation-py-script-type

Conversation

@jawwad-ali

Copy link
Copy Markdown
Contributor

What

The installation guide's Specify Script Type section documented only two script types (sh, ps) in its force-example block, and the installed-variant list mentioned only .specify/scripts/bash/ and .specify/scripts/powershell/. The CLI actually supports a third:

  • src/specify_cli/_agent_config.pySCRIPT_TYPE_CHOICES = {"sh": ..., "ps": ..., "py": "Python"}
  • src/specify_cli/commands/init.py--script help: "Script type to use: sh, ps, or py"
  • src/specify_cli/shared_infra.py (~L407) → script_type == "py" installs variant_dirs = ("python", <platform shell>), i.e. a python/ directory plus the platform shell fallback.

Fix

Two additions to docs/installation.md:

  • a specify init <project_name> --script py force example, and
  • a .specify/scripts/python/ bullet in the installed-variant list.

Docs-only. markdownlint-cli2 reports no new issues on the added lines (the two pre-existing MD049 findings at line 9 are unrelated and untouched).


AI-assisted: authored with Claude Code. I verified py against SCRIPT_TYPE_CHOICES, the --script option help, and the shared_infra.py variant-dir mapping.

The installation guide's "Specify Script Type" section only showed
`--script sh` and `--script ps`, and the installed-variant list only
mentioned `.specify/scripts/bash/` and `.specify/scripts/powershell/`.
The CLI has a third script type, `py`: `SCRIPT_TYPE_CHOICES` in
`_agent_config.py` includes `"py": "Python"`, and `shared_infra.py`
installs a `python/` variant directory (plus the platform shell fallback)
when `--script py` is chosen.

Add the missing `--script py` force example and a `.specify/scripts/python/`
bullet so the docs match the code. Docs-only.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Documents Python as a supported Specify script type.

Changes:

  • Adds a --script py example.
  • Documents the Python scripts directory and shell fallback.
Show a summary per file
File Description
docs/installation.md Adds Python script installation guidance.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Medium

Comment thread docs/installation.md
Address review feedback: update the section heading and intro so Python
is presented as a first-class script type alongside Shell and PowerShell,
matching the added --script py example and python/ variant directory.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jawwad-ali

Copy link
Copy Markdown
Contributor Author

Addressed the review feedback in 7e6ca7c: the section heading is now "Specify Script Type (Shell, PowerShell, or Python)" and the intro presents all three (.sh, .ps1, .py) as available variants, so Python reads as a first-class third type rather than an unexplained extra command.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review details

  • Files reviewed: 1/1 changed files
  • Comments generated: 0 new
  • Review effort level: Medium

@mnriem
mnriem merged commit 11ef1b3 into github:main Jul 22, 2026
14 checks passed
@mnriem

mnriem commented Jul 22, 2026

Copy link
Copy Markdown
Collaborator

Thank you!

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