ci: pyproject tests #5
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: test-dev | |
on: | |
push: | |
branches: | |
- dev | |
workflow_dispatch: {} | |
jobs: | |
style-check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Dev | |
uses: actions/checkout@v4 | |
- name: Checkout Main | |
run: git clone --depth 1 https://github.com/nypesap/mkdocs-nype.git main-branch | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3 | |
cache: pip | |
- name: Install style-check deps | |
run: pip install isort black | |
- name: Run style-check tests | |
run: | | |
isort mkdocs_nype/ --check | |
black mkdocs_nype/ --check | |
- name: Check package version when contents change | |
if: "hashFiles('mkdocs_nype') != hashFiles('main-branch/mkdocs_nype')" | |
run: | | |
wget -O main_pyproject.toml https://raw.githubusercontent.com/nypesap/mkdocs-nype/refs/heads/main/pyproject.toml | |
python .github/scripts/compare_pyproject.py --dev-toml pyproject.toml --main-toml main_pyproject.toml | |
check-repos: | |
needs: style-check | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
repo: | |
- https://github.com/nypesap/nypesap.github.io.git | |
- https://github.com/Fiori-Tracker/fioritracker.github.io.git | |
- https://github.com/fioriappsusage/fioriappsusage.github.io.git | |
- https://github.com/fioriroletesting/fioriroletesting.github.io.git | |
steps: | |
- uses: actions/checkout@v4 | |
- run: echo "${{ matrix.repo }}" | |
after-repos: | |
needs: check-repos | |
runs-on: ubuntu-latest | |
steps: | |
- run: echo "Success" |