Use common dgtized/carrier tasks for publishing over local copy #1458
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: Continuous Deployment | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| name: Build | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v7 | |
| - name: Cache deps.edn dependencies | |
| uses: actions/cache@v6 | |
| with: | |
| path: ~/.m2/repository | |
| key: clj-${{ runner.os }}-${{ hashFiles('**/deps.edn') }} | |
| restore-keys: clj-${{ runner.os }}- | |
| - name: Setup Java | |
| uses: actions/setup-java@v5 | |
| with: | |
| distribution: temurin | |
| java-version: 25 | |
| - name: Setup Clojure | |
| uses: DeLaGuardo/setup-clojure@13.6.1 | |
| with: | |
| cli: latest | |
| bb: latest | |
| - name: Install Chrome | |
| uses: browser-actions/setup-chrome@v2 | |
| with: | |
| chrome-version: 'stable' | |
| install-chromedriver: true | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v7 | |
| with: | |
| node-version: 24 | |
| - name: Build | |
| run: bb build | |
| - name: Lint | |
| run: bin/lint | |
| - name: Test CLJC | |
| run: bin/kaocha unit-cljc | |
| # - name: Test CLJS | |
| # run: xvfb-run --auto-servernum bin/cljs-test | |
| - name: Upload artifact | |
| id: deployment | |
| uses: actions/upload-pages-artifact@v5 | |
| with: | |
| path: 'static-site' | |
| publish: | |
| name: Publish | |
| needs: build | |
| runs-on: ubuntu-latest | |
| permissions: | |
| pages: write | |
| id-token: write | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Configure Pages | |
| uses: actions/configure-pages@v6 | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v5 |