diff --git a/README.md b/README.md index d0bb092..c48b632 100644 --- a/README.md +++ b/README.md @@ -95,6 +95,7 @@ jobs: with: token: ${{ secrets.GITHUB_TOKEN }} # Auto-generated token labels: true # Auto-label issues/PRs using AI + python-version: "3.13" # Optional: set up a specific Python version python: true # Format Python with Ruff python_docstrings: true # Format Python docstrings (default: true) biome: true # Format JS/TS with Biome (auto-detected via biome.json) diff --git a/action.yml b/action.yml index 894f040..0ed4d68 100644 --- a/action.yml +++ b/action.yml @@ -18,6 +18,10 @@ inputs: description: "Run Python formatting" required: false default: "false" + python-version: + description: "Python version to set up before running Python tooling" + required: false + default: "" python_docstrings: description: "Run Python docstring formatting" required: false @@ -100,6 +104,12 @@ inputs: runs: using: "composite" steps: + - name: Setup Python + if: inputs.python-version != '' + uses: actions/setup-python@v6 + with: + python-version: ${{ inputs.python-version }} + - uses: astral-sh/setup-uv@v7 with: ignore-empty-workdir: true