Replace African Transport and Regional Economic metadata from NISMOD #77
Workflow file for this run
This file contains hidden or 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: Generate markdown from new JSON metadata on PR open/synchronize | |
| on: | |
| pull_request: | |
| types: [opened, synchronize] | |
| branches: | |
| - rdl-0.** | |
| permissions: | |
| contents: write | |
| jobs: | |
| markdown: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: ./python | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| ref: ${{ github.head_ref }} | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.13' | |
| cache: 'pip' | |
| - run: python3 -m venv .venv | |
| - run: source .venv/bin/activate | |
| - run: echo 'Cython < 3.0' > /tmp/constraint.txt && PIP_CONSTRAINT=/tmp/constraint.txt pip install 'PyYAML==6.0.0' | |
| - run: python3 -m pip install -r requirements.txt | |
| - name: Generate markdown from new JSON metadata | |
| run: python3 main.py --ci --markdown | |
| - name: Commit results | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
| git add .. | |
| git diff-index --quiet HEAD || git commit -m "Generate markdown from new JSON metadata" | |
| git push | |
| echo "Complete" |