Skip to content

chore(deps-dev): bump the dependencies group with 2 updates #66

chore(deps-dev): bump the dependencies group with 2 updates

chore(deps-dev): bump the dependencies group with 2 updates #66

Workflow file for this run

---
name: CI/CD
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
inputs:
mode:
description: Release and deploy mode
required: true
type: choice
default: deploy-latest-build
options:
- release-and-deploy
- deploy-latest-build
- release-only
permissions:
contents: write
pages: write
id-token: write
pull-requests: write
issues: write
concurrency:
group: pages
cancel-in-progress: false
env:
MISE_TRUSTED_CONFIG_PATHS: ${{ github.workspace }}
PUPPETEER_SKIP_DOWNLOAD: true
jobs:
verify-workflows:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Verify GitHub Action commit pins
env:
GH_TOKEN: ${{ github.token }}
run: ./script/verify-github-action-pins
commitlint:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Validate pull request commits
if: github.event_name == 'pull_request'
run: aube exec commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose
- name: Validate push commit
if: github.event_name == 'push'
run: aube exec commitlint --from HEAD~1 --to HEAD --verbose
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Lint
run: ./script/lint
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Test
run: ./script/test
audit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Audit dependencies
run: ./script/audit
build:
needs: [lint, test, audit]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Build
run: ./script/build
- name: Upload build artifact
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: dist
path: ./dist
retention-days: 1
map-dom-budget:
needs: build
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Download build artifact
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: dist
path: dist
- name: Install Chrome for Puppeteer
run: ./script/install-chrome-for-puppeteer
- name: Map DOM budget smoke test
run: ./script/smoke
check-docs-only:
runs-on: ubuntu-latest
outputs:
skip-release: ${{ steps.check.outputs.skip-release }}
should-deploy-pages: ${{ steps.check.outputs.should-deploy-pages }}
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Check if changes are docs-only
id: check
run: |
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
case "${{ github.event.inputs.mode }}" in
release-and-deploy|release-only)
echo "Manual run: semantic release requested"
echo "skip-release=false" >> ${GITHUB_OUTPUT}
echo "should-deploy-pages=false" >> ${GITHUB_OUTPUT}
;;
deploy-latest-build)
echo "Manual run: deploy latest build without release"
echo "skip-release=true" >> ${GITHUB_OUTPUT}
echo "should-deploy-pages=true" >> ${GITHUB_OUTPUT}
;;
esac
exit 0
fi
if [ "${{ github.event_name }}" != "push" ] || [ "${{ github.ref }}" != "refs/heads/main" ]; then
echo "Not a push to main, using defaults"
echo "skip-release=false" >> ${GITHUB_OUTPUT}
echo "should-deploy-pages=false" >> ${GITHUB_OUTPUT}
exit 0
fi
commit_sha="${{ github.sha }}"
parent_sha=$(git rev-parse ${commit_sha}^ 2>/dev/null || echo "")
if [ -n "$parent_sha" ]; then
changed_files=$(git diff --name-only ${parent_sha} ${commit_sha} 2>/dev/null || echo "")
else
changed_files=$(git diff --name-only HEAD~1 HEAD 2>/dev/null || echo "")
fi
non_docs_files=$(echo "$changed_files" | grep -Ev '^(docs/|specs/|CONTEXT\.md|README\.md|\.github/)' | grep -v '^$' || true)
if [ -z "$non_docs_files" ]; then
echo "Docs-only changes, skipping release but deploying Pages"
echo "skip-release=true" >> ${GITHUB_OUTPUT}
echo "should-deploy-pages=true" >> ${GITHUB_OUTPUT}
else
echo "Non-docs files changed, proceeding with release"
echo "Changed files:"
echo "$changed_files"
echo "skip-release=false" >> ${GITHUB_OUTPUT}
echo "should-deploy-pages=false" >> ${GITHUB_OUTPUT}
fi
release:
needs: [build, check-docs-only]
if: |
github.ref == 'refs/heads/main' &&
(
(
github.event_name == 'push' &&
needs.check-docs-only.outputs.skip-release != 'true'
) ||
(
github.event_name == 'workflow_dispatch' &&
(
github.event.inputs.mode == 'release-and-deploy' ||
github.event.inputs.mode == 'release-only'
)
)
)
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup mise
uses: jdx/mise-action@dad1bfd3df957f44999b559dd69dc1671cb4e9ea # v4
with:
install: true
- name: Cache aube store
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.local/share/aube/store
key: ${{ runner.os }}-aube-${{ hashFiles('aube-lock.yaml') }}
restore-keys: |
${{ runner.os }}-aube-
- name: Install dependencies
run: ./script/ci-install
- name: Semantic Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: aube run release
- name: Pull release commit
run: git fetch origin main && git checkout main && git pull origin main
- name: Install Chrome for Puppeteer
run: |
sudo apt-get update
sudo apt-get install -y wget gnupg
wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" | sudo tee /etc/apt/sources.list.d/google-chrome.list
sudo apt-get update
sudo apt-get install -y google-chrome-stable
- name: Generate screenshots
run: |
export DISPLAY=:99
export PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome
Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
sleep 2
./script/screenshots
- name: Build with screenshots
run: ./script/build
- name: Upload release build artifact
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: dist-release
path: ./dist
retention-days: 1
deploy-pages-after-release:
needs: [release, map-dom-budget, check-docs-only]
if: |
github.ref == 'refs/heads/main' &&
(
(
github.event_name == 'push' &&
needs.check-docs-only.outputs.skip-release != 'true'
) ||
(
github.event_name == 'workflow_dispatch' &&
github.event.inputs.mode == 'release-and-deploy'
)
)
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Setup Pages
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6
- name: Download release build artifact
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: dist-release
path: dist
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
with:
path: ./dist
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5
deploy-pages-after-build:
needs: [build, map-dom-budget, check-docs-only]
if: |
github.ref == 'refs/heads/main' &&
(
(
github.event_name == 'push' &&
needs.check-docs-only.outputs.should-deploy-pages == 'true'
) ||
(
github.event_name == 'workflow_dispatch' &&
github.event.inputs.mode == 'deploy-latest-build'
)
)
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Setup Pages
uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6
- name: Download build artifact
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: dist
path: dist
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
with:
path: ./dist
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5