Files
nvm/.github/workflows/toc.yml
T
Jordan Harband 799de1d2dc [actions] TOC: use node/install instead of setup-node
`lts/*` is now node 26, which is not in the runner's tool cache,
so `setup-node` downloads it from a GitHub release asset host that the harden-runner allowlist blocks.
`node/install` installs node with nvm from nodejs.org, like the other workflows.
2026-11-02 13:42:07 -06:00

44 lines
1.1 KiB
YAML

name: update readme TOC
on: [push]
permissions:
contents: read
jobs:
_:
permissions:
contents: write
name: "update readme TOC"
runs-on: ubuntu-latest
steps:
- name: Harden Runner
uses: step-security/harden-runner@v2
with:
allowed-endpoints:
github.com:443
raw.githubusercontent.com:443
nodejs.org:443
registry.npmjs.org:443
api.github.com:443
- uses: actions/checkout@v6
with:
# https://github.com/actions/checkout/issues/217#issue-599945005
# pulls all commits (needed for lerna / semantic release to correctly version)
fetch-depth: "0"
# pulls all tags (needed for lerna / semantic release to correctly version)
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- uses: ljharb/actions/node/install@main
name: 'nvm install lts/* && npm install'
with:
node-version: 'lts/*'
- run: npm run doctoc
- name: commit changes
uses: ljharb/actions-js-build/commit@v3+amendpush
with:
amend: true
force: true