Skip to content

CI/CD

Trigger: Push to main

on:
push:
branches: [main]
StepCommandPurpose
Checkoutactions/checkout@v4Clone the repo
pnpm setuppnpm/action-setup@v4Install pnpm v9
Node setupactions/setup-node@v4Node 20, GPR registry, pnpm cache
Installpnpm install --frozen-lockfileInstall deps (lockfile must be up to date)
Buildpnpm turbo run build --filter=@thulanek/semtest-runnerBuild the main package only
Testpnpm turbo run test --filter=@thulanek/semtest-runnerRun vitest
Publishpnpm publish --no-git-checksPublish to GitHub Packages
permissions:
contents: read
packages: write

The publish step uses GITHUB_TOKEN (automatically provided by GitHub Actions) as NODE_AUTH_TOKEN. No manual secret setup is needed — the token has packages:write scope from the permissions block.

Only @thulanek/semtest-runner is built and tested. The docs sites are not part of the publish pipeline.

Trigger: Push to release

on:
push:
branches: [release]

Same as stable, except the publish step:

  1. Reads the current version from package.json
  2. Appends -rc.{run_number} (e.g. 0.1.0-rc.5)
  3. Publishes with the rc dist-tag
Terminal window
VERSION=$(node -p "require('./package.json').version")
npm version "${VERSION}-rc.${GITHUB_RUN_NUMBER}" --no-git-tag-version
pnpm publish --no-git-checks --tag rc

This means:

  • RC versions auto-increment via the GitHub Actions run number
  • Installing @thulanek/semtest-runner@rc gets the latest RC
  • Installing without a tag always gets the latest stable
  • The version bump is not committed — it only affects the published artifact