Skip to content

refactor(autoflow): derive version anchors from PREVIOUS_PACKAGE_VERSION (#281)#367

Merged
SisyphusZheng merged 1 commit into
devfrom
fix/281-version-anchor-single-source
Jul 9, 2026
Merged

refactor(autoflow): derive version anchors from PREVIOUS_PACKAGE_VERSION (#281)#367
SisyphusZheng merged 1 commit into
devfrom
fix/281-version-anchor-single-source

Conversation

@SisyphusZheng

Copy link
Copy Markdown
Member

Summary

  • Replaces hard-coded `0.41.0-alpha.5` literals in `updateCurrentVersionAnchors` with a single source of truth: `PREVIOUS_PACKAGE_VERSION` / `PREVIOUS_PACKAGE_VERSION_TAG` (added to `tools/project-constants.ts`).
  • Fixes the README anchor that wraps across a line break (embedded newline in the from-string).
  • Drops dead anchors whose target text no longer exists in the docs (README bold line, README.zh bold lines, VERSION_PLAN legacy line).
  • Makes `updateCurrentVersionAnchors` skip-with-warning instead of throwing when an anchor drifts, so a release is never blocked by stale documentation.
  • Adds `tools/autoflow/tests/release.test.ts` covering the builder (derivation from PREVIOUS_*, file existence, idempotent re-run).

Test plan

  • `deno test tools/autoflow/tests/release.test.ts` — 3 passing.
  • `deno lint` on changed files — clean.
  • `deno check tools/autoflow/release.ts` — clean.

Closes #281

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 9, 2026

Copy link
Copy Markdown

Deploying openelement with  Cloudflare Pages  Cloudflare Pages

Latest commit: 76e8d92
Status: ✅  Deploy successful!
Preview URL: https://f4dc7df8.lessjs.pages.dev
Branch Preview URL: https://fix-281-version-anchor-singl.lessjs.pages.dev

View logs

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

APIError: Insufficient Balance

opencode session  |  github run

…ION (#281)

- Replace hard-coded 0.41.0-alpha.5 literals with single-source-of-truth
  PREVIOUS_PACKAGE_VERSION / PREVIOUS_PACKAGE_VERSION_TAG.
- Fix README anchor that wraps across a line break (embedded newline).
- Drop dead anchors whose target text no longer exists in the docs.
- Make updateCurrentVersionAnchors skip (warn) instead of throw on drift.
- Add tools/autoflow/__tests__/release.test.ts covering the builder.
@SisyphusZheng SisyphusZheng force-pushed the fix/281-version-anchor-single-source branch from 1962217 to 76e8d92 Compare July 9, 2026 06:15
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

APIError: Insufficient Balance

opencode session  |  github run

@SisyphusZheng SisyphusZheng merged commit 881f403 into dev Jul 9, 2026
4 of 5 checks passed
@SisyphusZheng SisyphusZheng deleted the fix/281-version-anchor-single-source branch July 9, 2026 06:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant