-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workflow to update requirements.txt
- Loading branch information
1 parent
87e9d4b
commit 64ba371
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Pip compile and upgrade | ||
on: | ||
pull-request: | ||
jobs: | ||
upgrade-dependencies: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout infrastructure | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: main | ||
repository: equinor/isar-robot | ||
ssh-key: ${{ secrets.DeployKey }} | ||
|
||
- name: Set up Python 3.12 | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: "3.12" | ||
|
||
- name: Install pip-tools | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pip-tools | ||
- name: Upgrade dependencies and compile requirements file | ||
run: | | ||
pip-compile --output-file=requirements.txt pyproject.toml --upgrade | ||
- name: Checkout and commit | ||
run: | | ||
git config --global user.email "${EMAIL}" | ||
git config --global user.name "GitHub Actions (${NAME})" | ||
git add requirements.txt | ||
git commit --message "GHA: Upgrade dependencies in requirements.txt" | ||
git push |