Pull mod data from Mod Garden platform #27
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: Pull mod data from Mod Garden platform | |
| on: | |
| # Allows you to run this workflow manually from the Actions tab | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| env: | |
| PACKWIZ_COMMIT: c3a6e56882f46459db8ce62a3e5461057cd69085 | |
| PACKWIZ_DIR: /tmp/packwiz_artifact | |
| PACKWIZ: /tmp/packwiz_artifact/packwiz | |
| jobs: | |
| run: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| # Set up dependencies | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install python dependencies | |
| run: pip install -r requirements.txt | |
| - name: Cache Packwiz | |
| id: cache-packwiz | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ env.PACKWIZ_DIR }} | |
| key: packwiz-${{ env.PACKWIZ_COMMIT }} | |
| - if: ${{ steps.cache-packwiz.outputs.cache-hit != 'true' }} | |
| name: Download Packwiz | |
| uses: dawidd6/action-download-artifact@v8 | |
| with: | |
| github_token: ${{secrets.GITHUB_TOKEN}} | |
| repo: ModGardenEvent/packwiz | |
| workflow: go.yml | |
| name: "Linux 64-bit x86" | |
| path: ${{ env.PACKWIZ_DIR }} | |
| commit: ${{ env.PACKWIZ_COMMIT }} | |
| allow_forks: true | |
| - name: Make packwiz executable | |
| run: chmod +x ${{ env.PACKWIZ }} | |
| # Run and commit | |
| - name: Build pack | |
| run: python scripts/pull_platform.py | |
| - uses: stefanzweifel/git-auto-commit-action@v5 | |
| with: | |
| commit_message: Pull platform data |