Skip to content

Commit

Permalink
Add workflow to check and update requirements files
Browse files Browse the repository at this point in the history
This workflow runs an action on a pull request into main that
compiles the requirements files; opens a pull request if changes
are detected; and then exits successfully if no changes are detected
or unsuccessfully if changes are detected.
  • Loading branch information
amstilp committed May 24, 2024
1 parent 3fdd5c8 commit 8130b89
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/pip-compile.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Update pip-tools requirements files
on:
pull_request:
branches: [ "main" ]


jobs:
update-requirements-files:
runs-on: ubuntu-latest

steps:
- name: Checkout Code Repository
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}

- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: 3.9

- name: Update requirements files
uses: UW-GAC/pip-tools-actions/update-requirements-files@v1
with:
requirements_files: |-
requirements/requirements.in
requirements/test-requirements.in
requirements/dev-requirements.in
pr-branch-suffix: "${{ github.event.number}}"

0 comments on commit 8130b89

Please sign in to comment.