-
Notifications
You must be signed in to change notification settings - Fork 16
49 lines (39 loc) · 1.17 KB
/
model_compliance.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: MHub Contribution Check
on:
pull_request:
branches:
- "main"
env:
PR_NUMBER: ${{ github.event.number }}
jobs:
test:
name: Setup Compliance
runs-on: ubuntu-latest
steps:
# Checkout the latest code from the repo
- name: Checkout repo
uses: actions/checkout@v4
# Setup which version of Python to use
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: 3.8
# Display the Python version being used
- name: Display Python version
run: python -c "import sys; print(sys.version)"
# Install Python dependencies
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install requests jsonschema
# Get the list of files modified in the PR
- name: Get files modified in PR
id: modified_files
uses: Ana06/[email protected]
with:
format: json
# Run check script
- name: Run MHub compliance test
run: python .github/scripts/mhub_check.py
env:
MODIFIED_FILES: ${{ steps.modified_files.outputs.all }}