-
Notifications
You must be signed in to change notification settings - Fork 40
49 lines (49 loc) · 1.38 KB
/
CI.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: CI
on:
push:
branches: [ main ]
paths-ignore:
- 'README.md'
- 'LICENSE'
pull_request:
branches: [ main ]
paths-ignore:
- '.**'
- 'README.md'
- 'LICENSE'
env:
PYTHON_VERSION: "3.10"
jobs:
validate-mappings:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v2
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Download schema
run: wget -O custom_mappings_schema.json https://raw.githubusercontent.com/RickDB/PlexAniSync/master/custom_mappings_schema.json
- name: Validate mappings
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
python validate.py
sort-mappings:
if: github.event_name == 'push'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v2
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Sort entries
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
python sort.py
- name: Commit changes from sorting
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Sort entries