-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
automate to catch bugs earlier, we'll stay with requirements that lac…
…k *.VERSION.txt filename
- Loading branch information
Showing
1 changed file
with
60 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,60 @@ | ||
name: Upgrade | ||
|
||
on: | ||
workflow_dispatch: null | ||
schedule: | ||
# Every Monday, 7:30 AM (Berlin) | ||
- cron: "30 5 * * 1" | ||
|
||
# Backend | ||
jobs: | ||
pip_compile_multi: | ||
if: github.repository == 'maxplanck-ie/parkour2' | ||
runs-on: ubuntu-latest | ||
strategy: | ||
max-parallel: 4 | ||
matrix: | ||
python-version: ['3.10', 3.11, 3.12] | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
cache: "pip" | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
cache: "pip" | ||
python-version: "3.11" | ||
|
||
- run: pip install pip-compile-multi | ||
- run: | | ||
ls backend/requirements/*.in | cut -d'/' -f3 | rev | cut -d. -f2 | rev | \ | ||
xargs -I{} mv backend/requirements/{}.in backend/requirements/{}.${{ matrix.python-version }}.in | ||
pip-compile-multi -d backend/requirements --backtracking --autoresolve --allow-unsafe | ||
- uses: peter-evans/create-pull-request@v6 | ||
with: | ||
branch: create-pull-request/pip-compile-multi | ||
title: Update python dependencies. | ||
body: Update all python dependencies. | ||
delete-branch: true | ||
labels: | | ||
Dependencies | ||
commit-message: | | ||
Update python dependencies. | ||
Run of `pip-compile-multi` to upgrade all python dependencies. | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r backend/requirements/prod.${{ matrix.python-version }}.txt | ||
# Frontend (VueJS) | ||
# TODO: see Makefile rule: ncu. |