mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-20 06:21:13 +01:00
Mutable action tags are a supply-chain risk: a moved tag runs different code without a diff. Every workflow action is now pinned through .github/workflows/actions.lock, and CI verifies the lockfile so an out-of-sync or tampered one fails instead of running.
60 lines
1.3 KiB
YAML
60 lines
1.3 KiB
YAML
name: changelog
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- ".github/workflows/changelog.yml"
|
|
- "CHANGELOG.md"
|
|
- "xtask/**/*"
|
|
types:
|
|
- opened
|
|
- synchronize
|
|
- reopened
|
|
- labeled
|
|
- unlabeled
|
|
|
|
env:
|
|
#
|
|
# Dependency versioning
|
|
#
|
|
|
|
# This is the MSRV used by all repository infrastructure.
|
|
REPO_MSRV: "1.96.1"
|
|
|
|
#
|
|
# Environment variables
|
|
#
|
|
|
|
CARGO_INCREMENTAL: false
|
|
CARGO_TERM_COLOR: always
|
|
RUST_LOG: info
|
|
RUST_BACKTRACE: "1"
|
|
CACHE_SUFFIX: c # cache busting
|
|
|
|
jobs:
|
|
changelog:
|
|
timeout-minutes: 2
|
|
|
|
name: Check changelog for errors
|
|
runs-on: ubuntu-24.04
|
|
|
|
permissions: {}
|
|
|
|
steps:
|
|
- name: Harden runner
|
|
uses: step-security/harden-runner@v2.22.4
|
|
with:
|
|
egress-policy: audit
|
|
- name: Checkout repo
|
|
uses: actions/checkout@v7.0.1
|
|
with:
|
|
fetch-depth: 0
|
|
persist-credentials: false
|
|
|
|
# NOTE: Keep label name(s) in sync. with `xtask`'s implementation.
|
|
- name: Run `cargo xtask changelog …`
|
|
env:
|
|
GITHUB_EVENT_PULL_REQUEST_BASE_REF: ${{ github.event.pull_request.base.ref }}
|
|
run: |
|
|
cargo xtask changelog "origin/${GITHUB_EVENT_PULL_REQUEST_BASE_REF}" ${{ contains(github.event.pull_request.labels.*.name, 'changelog: released entry changed') && '--allow-released-changes' || '' }}
|