Bump ruby from 3.3.4-alpine to 3.3.5-alpine #4386
Workflow file for this run
This file contains 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
--- | |
on: | |
pull_request: | |
push: | |
branches-ignore: | |
- gh-pages | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 | |
- uses: ruby/setup-ruby@a6e6f86333f0a2523ece813039b8b4be04560854 | |
with: | |
bundler-cache: true | |
- uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b | |
with: | |
node-version: '16' | |
- name: Cache node modules | |
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: npm-${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
npm-${{ runner.os }}-build-${{ env.cache-name }}- | |
npm-${{ runner.os }}-build- | |
npm- | |
- name: Install NPM dependencies | |
run: npm install | |
- name: Test | |
run: bundle exec rspec | |
- name: Lint | |
run: bundle exec rubocop --parallel | |
- name: Validate schema | |
run: bundle exec rake schema | |
- name: Build | |
run: bundle exec rake build | |
- name: Upload built site | |
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 | |
with: | |
name: site | |
path: build | |
retention-days: 1 | |
htmlproofer: | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 | |
- uses: ruby/setup-ruby@a6e6f86333f0a2523ece813039b8b4be04560854 | |
with: | |
bundler-cache: true | |
- name: Download built site | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 | |
with: | |
name: site | |
path: build | |
- name: Test built site | |
run: bundle exec rake htmlproofer | |
publish: | |
runs-on: ubuntu-latest | |
if: ${{ github.ref == 'refs/heads/main' }} | |
needs: build | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 | |
- uses: ruby/setup-ruby@a6e6f86333f0a2523ece813039b8b4be04560854 | |
with: | |
bundler-cache: true | |
- name: Download built site | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 | |
with: | |
name: site | |
path: build | |
# Checkout stripped-down gh-pages branch to a subdirectory, for publishing | |
- name: Checkout gh-pages branch | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 | |
with: | |
ref: gh-pages | |
path: tmp/publish | |
- name: Publish | |
run: | | |
git config --global user.email "github-actions@github.com" | |
git config --global user.name "github-actions" | |
bundle exec rake publish CLONED_GH_PAGES_DIR="tmp/publish" |