File tree Expand file tree Collapse file tree 2 files changed +77
-12
lines changed
Expand file tree Collapse file tree 2 files changed +77
-12
lines changed Original file line number Diff line number Diff line change 1+ name : " BioNeMo Recipes CI"
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ - " pull-request/[0-9]+"
8+ - " dependabot/**"
9+ merge_group :
10+ types : [checks_requested]
11+ schedule :
12+ - cron : " 0 7 * * *" # Runs at 7 AM UTC daily (12 AM MST)
13+
14+ defaults :
15+ run :
16+ shell : bash -x -e -u -o pipefail {0}
17+
18+ concurrency :
19+ group : ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
20+ cancel-in-progress : true
21+
22+ jobs :
23+ changed-files :
24+ if : github.event_name != 'schedule'
25+ runs-on : ubuntu-latest
26+ outputs :
27+ any_changed : ${{ steps.changed-files.outputs.changed_directories }}
28+ steps :
29+ - uses : actions/checkout@v4
30+ with :
31+ fetch-depth : 0
32+ - uses : step-security/changed-files@v46
33+ id : changed-files
34+ with :
35+ base_sha : main
36+ dir_names : true
37+ dir_names_max_depth : 2
38+ files : |
39+ 'models/**'
40+ 'recipes/**'
41+ - name : List all changed files
42+ env :
43+ ALL_CHANGED_DIRECTORIES : ${{ steps.changed-files.outputs.all_changed_directories }}
44+ run : |
45+ for directory in ${ALL_CHANGED_DIRECTORIES}; do
46+ echo "$directory was changed"
47+ done
48+
49+ pre-commit :
50+ runs-on : ubuntu-latest
51+ needs : changed-files
52+ if : needs.changed-files.outputs.any_changed == 'true'
53+ steps :
54+ - uses : actions/checkout@v4
55+ with :
56+ fetch-depth : 0
57+ - uses : actions/setup-python@v5
58+ with :
59+ python-version : " 3.13"
60+ cache : " pip"
61+ - name : Setup UV
62+ uses : astral-sh/setup-uv@v6
63+ with :
64+ enable-cache : true
65+ - run : |
66+ uv tool install pre-commit --with pre-commit-uv --force-reinstall
67+ uv tool install tach>=0.9.0
68+ uv tool update-shell
69+ - run : ./ci/scripts/static_checks.sh
70+
Original file line number Diff line number Diff line change 2525 runs-on : ubuntu-latest
2626 outputs :
2727 any_changed : ${{ steps.changed-files.outputs.any_changed }}
28- docs_changed : ${{ steps.changed-files.outputs.docs_any_changed }}
2928 steps :
3029 - uses : actions/checkout@v4
3130 with :
@@ -34,15 +33,10 @@ jobs:
3433 id : changed-files
3534 with :
3635 base_sha : main
37- files_yaml : |
38- framework:
39- - '3rdparty/**'
40- - 'sub-packages/**'
41- - 'docker_build_patches/**'
42- - 'requirements-*.txt'
43- - 'Dockerfile'
44- docs:
45- - 'docs/**.ipynb'
36+ files : |
37+ '!models/**'
38+ '!recipes/**'
39+ '!**.md'
4640 - name : List all changed files
4741 env :
4842 ALL_CHANGED_FILES : ${{ steps.changed-files.outputs.all_changed_files }}
5347
5448 pre-commit :
5549 runs-on : ubuntu-latest
50+ needs : changed-files
51+ if : needs.changed-files.outputs.any_changed == 'true'
5652 steps :
5753 - uses : actions/checkout@v4
5854 with :
@@ -227,8 +223,7 @@ jobs:
227223 runs-on : linux-amd64-gpu-l4-latest-1
228224 if : |
229225 github.event_name == 'schedule' || github.event_name == 'merge_group' ||
230- contains(fromJSON(needs.get-pr-labels.outputs.labels || '[]'), 'INCLUDE_NOTEBOOKS_TESTS') ||
231- needs.changed-files.outputs.docs_changed == 'true'
226+ contains(fromJSON(needs.get-pr-labels.outputs.labels || '[]'), 'INCLUDE_NOTEBOOKS_TESTS')
232227 container :
233228 image : svcbionemo023/bionemo-framework:${{ github.run_id }}
234229 credentials :
You can’t perform that action at this time.
0 commit comments