chore: Rename Cloudflare secret to CLOUDFLARE_API_TOKEN, standardize wrangler-action@v4 #4
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: CI | |
| on: | |
| pull_request: | |
| branches: ["main"] | |
| # Prevent multiple concurrent runs | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| lint-and-test: | |
| runs-on: ubuntu-latest | |
| env: | |
| BUNDLE_PATH: "vendor/bundle" | |
| BUNDLE_JOBS: 4 | |
| BUNDLE_RETRY: 3 | |
| steps: | |
| - name: Checkout source | |
| uses: actions/checkout@v6 | |
| - name: Lint markdown | |
| uses: DavidAnson/markdownlint-cli2-action@v23 | |
| - name: Setup Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: 3.3 | |
| - name: Install dependencies | |
| run: | | |
| bundle install | |
| npm install -g pa11y-ci | |
| - name: Use 'localhost' | |
| uses: jacobtomlinson/gha-find-replace@v3 | |
| with: | |
| find: "https://stockindicators.dev" | |
| replace: "http://127.0.0.1:4000" | |
| regex: false | |
| - name: Build site | |
| run: bundle exec jekyll build | |
| - name: Serve site | |
| run: bundle exec jekyll serve --port 4000 --detach | |
| - name: Show environment | |
| run: npx pa11y --environment | |
| - name: Test accessibility | |
| run: > | |
| pa11y-ci | |
| --sitemap http://127.0.0.1:4000/sitemap.xml | |
| --config ./.pa11yci | |
| - name: Kill site (failsafe) | |
| if: always() | |
| run: pkill -f jekyll |