diff --git a/.github/workflows/tox.yml b/.github/workflows/tox.yml index eda4d93..6ab3127 100644 --- a/.github/workflows/tox.yml +++ b/.github/workflows/tox.yml @@ -54,6 +54,11 @@ on: description: Command to run after test commands. required: false type: string + default_node: + default: "" + description: Path to the Node.js version file (e.g., `.tool-versions`) + required: false + type: string # keep permissions at top level because this is a composite workflow permissions: checks: read @@ -120,6 +125,12 @@ jobs: cache: ${{ hashFiles('requirements.txt', 'pyproject.toml') && 'pip' || '' }} python-version: ${{ matrix.python_version || '3.12' }} + - name: Set up Node.js + if: ${{ inputs.default_node != '' }} + uses: actions/setup-node@v3 + with: + node-version-file: ${{ inputs.default_node }} + - name: Run pre if: ${{ inputs.run_pre }} run: ${{ inputs.run_pre }}