Ranma ½ (2024) #31
Workflow file for this run
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
name: TVDB | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
paths: | |
- "custom_mappings.yaml" | |
- "**.py" | |
env: | |
PYTHON_VERSION: "3.10" | |
jobs: | |
validate-added-mappings: | |
runs-on: ubuntu-latest | |
steps: | |
# TODO: maybe make this step a pre-requisite to any CI flow | |
- name: Prevent file change | |
uses: xalvarez/prevent-file-change-action@v1 | |
with: | |
githubToken: ${{ secrets.GITHUB_TOKEN }} | |
pattern: .*\.py | |
trustedAuthors: evie-lau | |
allowNewFiles: false | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python ${{ env.PYTHON_VERSION }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ env.PYTHON_VERSION }} | |
- name: Cache python env | |
uses: actions/cache@v4 | |
with: | |
path: ${{ env.pythonLocation }} | |
key: ${{ env.pythonLocation }}-${{ hashFiles('validate-tvdb.py') }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install tvdb_v4_official python-dotenv pyyaml | |
- name: Run season validation against TVDB | |
env: | |
TVDB_API_KEY: ${{ secrets.TVDB_API_KEY }} | |
run: python validate-tvdb.py |