| on: |
| workflow_dispatch: {} |
| schedule: |
| # Sunday |
| - cron: '20 20 * * 0' |
| |
| name: "pip-compile: create PR" |
| jobs: |
| pip_compile: |
| name: pip-compile |
| runs-on: ubuntu-latest |
| steps: |
| - name: Setup Python |
| uses: actions/setup-python@v2 |
| with: |
| python-version: 3.8 |
| - name: pip-compile |
| uses: technote-space/create-pr-action@v2 |
| with: |
| EXECUTE_COMMANDS: | |
| pip install pip-tools |
| pip-compile -U --generate-hashes docs-requirements.in |
| pip-compile -U --generate-hashes pidiff-requirements.in |
| pip-compile -U --generate-hashes requirements.in |
| pip-compile -U --generate-hashes test-requirements.in |
| COMMIT_MESSAGE: 'chore: scheduled pip-compile' |
| COMMIT_NAME: 'GitHub Actions' |
| COMMIT_EMAIL: 'noreply@github.com' |
| PR_BRANCH_PREFIX: deps/ |
| PR_BRANCH_NAME: 'pip-compile' |
| PR_TITLE: 'chore: scheduled pip-compile' |
| PR_BODY: |- |
| ## Update dependencies |
| |
| This is a scheduled update of Python dependencies within this |
| repo managed by pip-compile. |
| |
| This change will be approved automatically and merged within |
| a few days if all checks have succeeded. |
| - name: Look up pull request |
| uses: juliangruber/find-pull-request-action@v1 |
| id: find-pull-request |
| with: |
| branch: deps/pip-compile |
| - run: echo "Pull Request ${number} (${sha})" |
| env: |
| number: ${{ steps.find-pull-request.outputs.number }} |
| sha: ${{ steps.find-pull-request.outputs.head-sha }} |
| - name: Approve Pull Request |
| uses: juliangruber/approve-pull-request-action@v1 |
| with: |
| github-token: ${{ secrets.APPROVAL_TOKEN }} |
| number: ${{ steps.find-pull-request.outputs.number }} |