name: Deploy to Pages on: push: branches: ['main'] pull_request: branches: ['main'] workflow_dispatch: concurrency: group: 'pages' cancel-in-progress: false jobs: build: runs-on: docker steps: - uses: actions/checkout@v4 - name: Setup Node uses: actions/setup-node@v4 with: node-version-file: '.nvmrc' cache: 'npm' - name: Install dependencies run: npm ci - name: Lint run: npm run lint - name: Typecheck run: npm run typecheck - name: Check for em dashes run: npm run qa:no-em-dashes - name: Build run: npm run build - name: Astro audit run: npm run qa:astro-audit - name: Check internal links run: npm run qa:links - name: Check for unexpected JavaScript run: npm run qa:no-js - name: Check viewport overflow run: npm run qa:overflow - name: Check preview cropping run: npm run qa:preview-cropping - name: Copy build to host pages mount if: github.event_name == 'push' && github.ref == 'refs/heads/main' uses: http://forgejo:3000/andras/ci-actions/deploy-pages@main with: source: dist target: schmelczer-dev - name: Copy build to staging pages mount if: github.event_name == 'pull_request' uses: http://forgejo:3000/andras/ci-actions/deploy-pages@main with: source: dist target: schmelczer-dev-staging