Big documentation update #3359
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: Prevent deletion of database migration files | |
| "on": | |
| pull_request_target: # zizmor: ignore[dangerous-triggers] | |
| branches: [main] | |
| concurrency: # yamllint disable-line rule:key-ordering | |
| cancel-in-progress: true | |
| group: ${{github.workflow}}-${{github.event.pull_request.number || github.ref}} | |
| permissions: | |
| pull-requests: read # Needed to check if a pull request includes the deletion of a migration file | |
| jobs: | |
| prevent-migrations-deletion: | |
| name: Prevent deletion of database migration files | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: xalvarez/prevent-file-change-action@v3.0.1 | |
| with: | |
| allowNewFiles: true | |
| githubToken: ${{secrets.GITHUB_TOKEN}} | |
| pattern: .*\/db\/.+\/migrations\/\d{4}\w*\.py$ |