Yulia/app data update (#386) #205
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: deploy | |
| 'on': | |
| push: | |
| branches: | |
| - main | |
| - v*.*.* # only major.minor.patch versions | |
| env: | |
| CI: true | |
| GH_TOKEN: ${{ github.token }} | |
| # NOTE: insiders version must correspond to the mkdocs-material version in pyproject.toml | |
| # and must be updated in all .yml files in this directory | |
| INSIDERS_VERSION: 9.6.12-insiders-4.53.16 | |
| JUVIX_VERSION: v0.6.10 | |
| JUST_VERSION: 1.40.0 | |
| GIT_COMMITTER_EMAIL: arts@heliax.dev | |
| GIT_COMMITTER_NAME: Anoma Research | |
| REPORT_TODOS: false | |
| SHOW_TODOS_IN_MD: false | |
| BRANCH_NAME: ${{ github.head_ref || github.ref_name }} | |
| concurrency: | |
| group: "${{ github.workflow }}-${{ github.head_ref || github.run_id }}" | |
| cancel-in-progress: true | |
| permissions: | |
| contents: write | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| fetch-depth: 0 | |
| - run: | | |
| git config --global user.name 'Anoma Research' | |
| git config --global user.email 'arts@heliax.dev' | |
| - name: comment on PR | |
| run: gh $GH_FLAGS --edit-last --body "$MSG" || gh $GH_FLAGS --body "$MSG" || true | |
| env: | |
| MSG: "The build is in progress. Please wait for the preview link." | |
| GH_FLAGS: pr -R anoma/nspec comment ${{ github.event.pull_request.number }} | |
| - name: Install the right Juvix for the Specs | |
| uses: jaxxstorm/action-install-gh-release@v1 | |
| with: | |
| repo: anoma/juvix | |
| tag: ${{ env.JUVIX_VERSION }} | |
| cache: enable | |
| rename-to: juvix | |
| chmod: 0755 | |
| - uses: actions/cache@v4 | |
| with: | |
| key: juvix-cache-${{ hashFiles('**/*.juvix.md') }}-${{ hashFiles('**/*.juvix') }} | |
| path: .juvix-build | |
| restore-keys: | | |
| juvix-cache- | |
| - name: typecheck | |
| continue-on-error: true | |
| run: | | |
| juvix --log-level error typecheck docs/everything.juvix.md | |
| - name: Install the latest version of uv | |
| uses: astral-sh/setup-uv@v5 | |
| with: | |
| enable-cache: true | |
| - uses: extractions/setup-just@v2 | |
| with: | |
| just-version: ${{ env.JUST_VERSION }} # optional semver specification, otherwise latest | |
| - run: just setup-repo | |
| - name: Cache .cache-juvix-mkdocs | |
| uses: actions/cache@v4 | |
| with: | |
| key: cache-juvix-mkdocs-${{ env.cache_id }} | |
| path: .cache-juvix-mkdocs | |
| restore-keys: | | |
| cache-juvix-mkdocs- | |
| - name: Install Linux dependencies | |
| run: sudo apt-get install -y libcairo2-dev libfreetype6-dev libffi-dev libjpeg-dev libpng-dev libz-dev pngquant graphviz | |
| - name: get latest version from VERSION file | |
| id: version | |
| run: echo "::set-output name=version::$(cat VERSION)" | |
| - name: get the last commit short hash | |
| id: commit | |
| run: echo "::set-output name=commit::$(git rev-parse --short HEAD)" | |
| - name: Install material insiders version | |
| run: uv add git+https://${{ secrets.INSIDERS_TOKEN }}@github.com/squidfunk/mkdocs-material-insiders.git@${INSIDERS_VERSION} | |
| - name: Build MkDocs with material insiders version | |
| id: material | |
| run: | | |
| uv run mkdocs build --clean --config-file mkdocs.insiders.yml --site-dir $SITE_DIR | |
| env: | |
| SITE_DIR: ${{ env.BRANCH_NAME }} | |
| SITE_URL: https://specs.anoma.net/${{ env.BRANCH_NAME }}/ | |
| SITE_VERSION: ${{ steps.version.outputs.version }} | |
| COMMIT: ${{ steps.commit.outputs.commit }} | |
| COPYRIGHT: Powered by Mkdocs, Material ${{ env.INSIDERS_VERSION }} and Juvix ${{ env.JUVIX_VERSION }} | |
| PROCESS_JUVIX: true | |
| TIMELIMIT: 100 | |
| - if: success() | |
| uses: JamesIves/github-pages-deploy-action@v4 | |
| with: | |
| token: ${{ secrets.PAGES_TOKEN }} | |
| repository-name: anoma/specs.anoma.net | |
| branch: main | |
| folder: ${{ env.BRANCH_NAME }} | |
| target-folder: ${{ env.BRANCH_NAME }} | |
| clean: false | |
| git-config-name: Anoma Research | |
| git-config-email: arts@heliax.dev |