Add explicit workflow token permissions #243
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: pre-commit | |
| on: | |
| pull_request: | |
| permissions: | |
| contents: write | |
| jobs: | |
| pre-commit: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| persist-credentials: false | |
| - uses: actions/setup-python@v2 | |
| # Skip checks that don't auto-fix issues initially. | |
| - uses: pre-commit/action@v2.0.0 | |
| env: | |
| SKIP: remark,check-yaml,check-json,check-added-large-files | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| # Final run without committing to ensure passes. | |
| - uses: pre-commit/action@v2.0.0 | |
| env: | |
| # We skip checks that have their own actions. | |
| SKIP: remark. |