release-process
GitHub管理稳定版与RC版的发布流水线,涵盖分支命名到版本号的映射、自动触发流程、NPM/GHCR发布及故障排查。
Trigger Scenarios
Install
npx skills add lichtblick-suite/lichtblick --skill release-process -g -y
SKILL.md
Frontmatter
{
"name": "release-process",
"description": "Release pipeline knowledge covering the stable release flow (release.yml -> post-release.yml -> release-sync.yml), the manual pre-release\/RC flow (prerelease.yml), branch-naming to version-bump mapping, and NPM\/GHCR publishing. Use when cutting a release, verifying a completed release, or troubleshooting the release pipeline."
}
Release Process Skill
Overview
Lichtblick has two release tracks:
- Stable releases — triggered automatically when a merged pull request into
maincomes from arelease/*orhotfix/*branch. This runs.github/workflows/release.yml, which creates the GitHub Release and then fan-outs into post-release publishing and main→develop sync via GitHub'srelease: releasedevent. - Manual pre-release / RC builds — triggered manually through
.github/workflows/prerelease.yml(workflow_dispatchonly). This builds the same production artifacts and, whencreate_release: true, creates a GitHub Pre-release throughncipollo/release-actionwithprerelease: true. Because GitHub'sreleaseevent firesprereleased(notreleased) for pre-releases, this does not triggerpost-release.ymlorrelease-sync.yml— RC builds are never auto-published to NPM/GHCR or auto-synced todevelop.
The stable and RC flows share the same artifact packaging shape, but only the stable flow performs the in-repo version bump, commit, and tag push to main.
Branch Naming -> Version Bump Mapping
The version bump is computed by regex in the bump_type step of .github/workflows/release.yml.
| Branch prefix pattern | Bump type | Example |
|---|---|---|
hotfix/* |
patch |
hotfix/fix-crash |
release/major or release/major/* |
major |
release/major/v2.0.0 |
release/minor or release/minor/* |
minor |
release/minor/v1.5.0 |
Any other branch prefix causes the workflow to fail with an explicit error.
Stable Release Pipeline (release.yml)
Trigger condition:
on:
pull_request:
types: [closed]
branches:
- main
jobs:
release:
if: |
github.event.pull_request.merged == true &&
(startsWith(github.head_ref, 'release/') || startsWith(github.head_ref, 'hotfix/'))
Step order:
- Check out the repository on
main. - Set up Node.js 24 and enable Yarn via Corepack.
- Install dependencies with
yarn install --immutable. - Determine the bump type from the source branch name:
hotfix/*->patchrelease/major(/.*)?->majorrelease/minor(/.*)?->minor- anything else -> fail
- Bump the root version with
yarn version <type>. - Bump
packages/suite/package.jsonwithyarn version <type>. - Read the new version from the root
package.json. - Update
sonar-project.propertiessosonar.projectVersionmatches the new version. - Commit the version files and tag
mainasv${version}, then pushmainand tags. - Build the production desktop and web bundles:
yarn desktop:build:prodyarn web:build:prod
- Package release binaries for Windows, Linux, and macOS:
yarn package:winyarn package:linuxyarn package:darwin
- Create the web static tarball at
dist/lichtblick-web.tar.gz. - Create the GitHub Release with
ncipollo/release-action@v1. - Trigger
sonarqube.ymlonmainviagh workflow run.
Release artifacts:
dist/lichtblick-${version}-linux-amd64.debdist/lichtblick-${version}-linux-x64.tar.gzdist/lichtblick-${version}-linux-arm64.debdist/lichtblick-${version}-linux-arm64.tar.gzdist/lichtblick-${version}-mac-universal.dmgdist/lichtblick-${version}-win.exedist/lichtblick-web.tar.gzdist/latest-linux.ymldist/latest-mac.ymldist/latest.yml
Post-Release Publishing (post-release.yml)
Trigger:
release: types: [released]— fires only for full (non-prerelease) GitHub Releases; pre-releases fire GitHub's separateprereleasedevent, which this workflow does not listen for.- manual
workflow_dispatch— requires an explicittaginput (for examplev1.28.1). Both jobs usegithub.event.inputs.tag || github.event.release.tag_namefor the checkout ref and Docker version tagging, so a manual run publishes the specified tag instead of depending on release-event context.
This workflow fans out into two parallel jobs:
npm
Yarn (per the
packageManagerfield inpackage.json, currently 4.17.0) via Corepack remains this repo's dependency manager everywhere else;npm publishhere is an intentional, pipeline-only exception used solely to publish the built package to the npm registry.
- Check out the release tag (
github.event.release.tag_name). - Set up Node.js 24 and point npm at
https://registry.npmjs.org. - Enable Yarn and run
yarn install --immutable. - Publish
./packages/suiteto npm withnpm publish ./packages/suite.
docker
- Check out the same release tag.
- Set up QEMU and Docker Buildx.
- Log in to GHCR.
- Strip the leading
vfrom the release tag for the versioned container tag. - Build and push a multi-arch image for
linux/amd64,linux/arm64. - Push both:
ghcr.io/<repo>:latestghcr.io/<repo>:<version-without-v-prefix>
Release Sync (release-sync.yml)
Trigger:
release: types: [released]— same caveat aspost-release.yml: pre-releases fireprereleased, notreleased, so this workflow does not run for RC builds.- manual
workflow_dispatch
This workflow keeps develop descended from main after a release:
- Check out
mainwith full history. - Read the released version from
package.json. - Create
sync/main-to-develop-{version}fromorigin/develop. - Attempt
git merge origin/main --no-ff.
Two paths follow:
- Clean merge — push the sync branch, open a PR into
develop, and enable auto-merge withgh pr merge --merge --auto. - Conflicted merge — commit the conflict markers, push the branch, and open a PR whose body warns that conflicts must be resolved manually.
In both cases, the workflow emphasizes the same rule: merge the sync PR with a MERGE COMMIT only — never squash or rebase — so main remains an ancestor of develop.
Manual Pre-release / RC Flow (prerelease.yml)
This workflow is manual-only (workflow_dispatch).
| Input | Type / options | Default | Purpose |
|---|---|---|---|
branch |
choice (fixed dropdown values): develop, release/* |
develop |
Branch to build the pre-release from |
version_type |
choice: prerelease, prepatch, preminor, premajor |
prerelease |
How to compute the next RC version |
create_release |
boolean | true |
Whether to publish a GitHub Pre-release |
release_notes |
string | none | Optional custom release notes body |
Note:
release/*is a literal option string in the workflow'schoiceinput, not a wildcard/glob pattern. Selecting it only works if a branch is literally namedrelease/*; to build an RC from an actual release branch (e.g.release/minor/v1.5.0), that exact branch name would need to be added as its own choice option (or the input changed to a free-textstringtype).
Version computation logic:
- Check out the selected branch with full history.
- Find the latest RC tag matching
v*rc.*. - Compute the next version:
- If
version_type == "prerelease":- with no RC tag yet:
semver.inc(baseVersion, "prerelease", "rc") - with an existing RC tag:
semver.inc(lastRcWithoutLeadingV, "prerelease", "rc")
- with no RC tag yet:
- Otherwise:
- derive a stable base version from
package.json - run
semver.inc(stableBase, version_type, "rc")
- derive a stable base version from
- If
- Use the computed version for artifact naming and release metadata.
Build and release steps:
- Build production desktop and web bundles.
- Package Windows, Linux, and macOS artifacts using
--config.extraMetadata.version=${version}. - Create
dist/lichtblick-web.tar.gz. - If
create_release == true, create a GitHub Pre-release withncipollo/release-action@v1,prerelease: true, and the same artifact list as the stable release flow.
Note: This flow does not commit a version bump into git history. As covered above, GitHub fires
prereleased(notreleased) for pre-releases, sopost-release.ymlandrelease-sync.ymldo not run automatically after this workflow creates a GitHub Pre-release — NPM publishing, the GHCR image push, and the develop-sync PR only happen for stable releases.
Workflow Trigger Reference
| Workflow file | Trigger | Jobs |
|---|---|---|
.github/workflows/release.yml |
pull_request closed on main, gated to merged PRs whose head branch starts with release/ or hotfix/ |
release |
.github/workflows/post-release.yml |
release: released (excludes pre-releases) or workflow_dispatch (requires tag input) |
npm, docker |
.github/workflows/prerelease.yml |
workflow_dispatch |
prerelease |
.github/workflows/release-sync.yml |
release: released (excludes pre-releases) or workflow_dispatch |
sync |
Key Files
.github/workflows/release.yml.github/workflows/post-release.yml.github/workflows/prerelease.yml.github/workflows/release-sync.yml
Version History
- 6435710 Current 2026-08-16 02:35


