.agents/skills/release-openclaw-nightly/SKILL.md
Use for Tideclaw/OpenClaw alpha/nightly release automation, manual alpha triggers, beta prep, release-branch repair, and post-release forward-port. Load $release-private if it exists before using Tideclaw host paths, cron ids, or Discord routing ids.
main.main and prove main CI green.gh write wrapper below.Tideclaw should commit under its own machine identity on release branches and forward-port branches:
git config user.name "Tideclaw"
git config user.email "[email protected]"
This is good for auditability if commits are clearly machine-authored and gated by CI. Avoid direct pushes to protected main; forward-port via PR/automerge unless the repo policy explicitly allows the bot to push after green checks. Include human Co-authored-by only when a human supplied the patch or explicit commit text.
tideclaw/alpha/tideclaw/alpha/YYYY-MM-DD-HHMMZorigin/main SHA at trigger time.$release-private on the Tideclaw host.vYYYY.M.D-alpha.NalphaDo not reuse old alpha branches for a new run. If rerunning the same base SHA, create a new timestamped branch and record why.
$release-private.git fetch origin main --tags --prune
git switch main
git merge --ff-only origin/main
BASE_SHA="$(git rev-parse origin/main)"
BRANCH="tideclaw/alpha/$(date -u +%Y-%m-%d-%H%MZ)"
git switch -c "$BRANCH" "$BASE_SHA"
AGENTS.mddocs/scripts/.github/workflows/*release*$BASE_SHA with the last successful alpha state and current git/npm/GitHub alpha tags. If already released, report skip and do not publish.Manual trigger:
CRON_ID="<from release-private>"
OPENCLAW_ALLOW_ROOT=1 openclaw cron run "$CRON_ID" --expect-final --timeout 21600000
Tideclaw may run alpha immediately from Discord when a maintainer mentions Tideclaw in #releases or #maintainers.
Accepted shapes:
@Tideclaw run alpha now
@Tideclaw alpha release from main now
@Tideclaw trigger alpha
Rules:
origin/main and create a fresh tideclaw/alpha/YYYY-MM-DD-HHMMZ branch.#maintainers trigger requires an explicit Tideclaw mention; do not react to unmentioned release chatter there.$release-private.Tideclaw may run beta releases from #releases or mentioned #maintainers commands only when a maintainer sends an explicit beta trigger. Treat this as human approval for beta, not for stable/latest.
Accepted shapes:
@Tideclaw beta release from vYYYY.M.D-alpha.N
@Tideclaw beta release from tideclaw/alpha/YYYY-MM-DD-HHMMZ
@Tideclaw beta release from latest proven alpha
Rules:
beta release and a source alpha tag/branch, or latest proven alpha.#releases and stop.alpha package, release CI, recorded state file, and branch/tag SHA.tideclaw/beta/YYYY-MM-DD-HHMMZ from the proven alpha source, not directly from a moving main.vYYYY.M.D-beta.N, matching npm --tag beta.main using the same fixes-only PR rules below.Before running checks, mine recent Tideclaw alpha branches for fixes already made during previous release attempts:
$release-private for the last successful alpha branch and fix commit SHAs.git for-each-ref refs/remotes/origin/tideclaw/alpha --format='%(refname:short) %(committerdate:iso-strict)'
origin/main:git log --no-merges --reverse --format='%H%x09%s' origin/main..origin/tideclaw/alpha/YYYY-MM-DD-HHMMZ
fixCommitShas in the state file.Use git cherry, git range-diff, and targeted test reruns to avoid duplicating fixes already present on main.
Use the branch as a release-candidate repair surface:
Commit examples:
git add <files>
git commit -m "fix: stabilize alpha release preflight"
git push -u origin "$BRANCH"
After local proof:
vYYYY.M.D-alpha.N from existing git tags, npm versions, and GitHub releases.gh is a read-only Codex sandbox wrapper; use /usr/local/bin/gh-tideclaw-write for write-capable commands such as workflow run, run cancel, and publish dispatch:GH="/usr/local/bin/gh-tideclaw-write"
SHA="$(git rev-parse HEAD)"
TAG="v$(node -p "require('./package.json').version")"
BRANCH="$(git branch --show-current)"
"$GH" workflow run full-release-validation.yml --repo openclaw/openclaw --ref "$BRANCH" \
-f ref="$BRANCH" \
-f release_profile=beta \
-f rerun_group=all
"$GH" workflow run openclaw-npm-release.yml --repo openclaw/openclaw --ref "$BRANCH" \
-f tag="$SHA" \
-f preflight_only=true \
-f npm_dist_tag=alpha
gh run list, gh run view, and gh api. Read-only gh is fine for polling; use $GH only when a command mutates GitHub. Do not use Codex browser/fetch for GitHub API polling; prior Tideclaw runs failed there after successful preflight.rerun_group=all is stuck only on advisory lanes after CI, plugin prerelease, npm preflight, package preparation, and install smoke are green, dispatch a focused Full Release Validation on the same head with -f rerun_group=install-smoke. Use that successful focused Full Release Validation run as the publish proof, and include the separate CI/plugin/full advisory run IDs in the Discord summary.git tag -a "$TAG" "$SHA" -m "openclaw ${TAG#v}"
git push origin "$TAG"
"$GH" workflow run openclaw-release-publish.yml --repo openclaw/openclaw --ref "$BRANCH" \
-f tag="$TAG" \
-f preflight_run_id="$NPM_PREFLIGHT_RUN_ID" \
-f full_release_validation_run_id="$FULL_RELEASE_VALIDATION_RUN_ID" \
-f npm_dist_tag=alpha \
-f plugin_publish_scope=all-publishable \
-f publish_openclaw_npm=true \
-f release_profile=beta \
-f wait_for_clawhub=false
openclaw-npm-release.yml is waiting on the npm-release environment and Tideclaw cannot approve it, report that as the only blocker; do not call the release done.Important: openclaw-npm-release.yml with preflight_only=true only prepares artifacts. It does not publish. A successful alpha requires the later openclaw-release-publish.yml wrapper, a pushed git tag, npm alpha dist-tag proof, and a GitHub prerelease.
Release is not done until all are true:
npm view openclaw@<version> shows the exact version, dist-tag alpha, tarball, integrity, and publish time.$release-private records version, tag, base SHA, branch, fix commit SHAs, workflow run IDs, npm integrity, and timestamp.Final Discord summary in #releases:
Use Discord-safe Markdown links with angle-bracket targets. Never print secrets.
After a successful alpha, raise a fixes-only PR back to main:
origin/main:git fetch origin main --prune
git switch -c "tideclaw/forward-port/$(date -u +%Y-%m-%d-%H%MZ)" origin/main
If origin/main is independently red before the forward-port, document the unrelated failing check and still keep the forward-port PR green against its head when possible.
Before and after each run, prune old alpha branches:
origin/tideclaw/alpha/*.git push origin --delete tideclaw/alpha/YYYY-MM-DD-HHMMZ
Never delete human branches, beta branches, stable branches, or unknown prefixes.
Stop and report clearly if: