Files
advisory-db/.github/workflows/publish-web.yml
2026-07-01 13:19:11 +02:00

37 lines
1.1 KiB
YAML

name: Publish Web
on:
push:
branches: main
permissions: {}
jobs:
publish-web:
runs-on: ubuntu-latest
permissions:
contents: write # needed for pushing back to the repo
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
ref: gh-pages
persist-credentials: true # persists the token for git push below
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
id: admin-cache
with:
path: ~/.cargo/bin
key: rustsec-admin-eee63cf3c3916a9b8305678dfb91206acd9e67eb
- name: Install rustsec-admin
if: steps.admin-cache.outputs.cache-hit != 'true'
run: cargo install --git https://github.com/rustsec/rustsec rustsec-admin --rev eee63cf3c3916a9b8305678dfb91206acd9e67eb
- run: |
rustsec-admin web .
git config user.name github-actions
git config user.email github-actions@github.com
git add .
git commit -m "Update gh-pages" || true
git push || true