ci: tag the release commit and link the package to the repository #18

Merged
haylan merged 1 commits from ci/tag-and-link-release into main 2026-10-03 18:46:00 +00:00
Owner

The release workflow published the package but did not tag the commit or connect the package to this repository.

scripts/release.ts now, after publishing:

  • creates the git tag v<version> on the workflow's commit via the Gitea API (skips if it exists)
  • links the package to this repository via POST /packages/{owner}/npm/{name}/-/link/{repo} (skips if the package already has a repository)

Publishing, tagging and linking are each idempotent, so starting the workflow again completes a release that already published but was never tagged or linked. The workflow now passes SERVER_URL, REPOSITORY and SHA (replacing REGISTRY_URL).

  • 12 new tests with a fake Gitea API (42 total); npm run check passes
  • I checked read-only against git.arthurerlich.de that the tag lookup and the encoded scoped package path route correctly (404 JSON messages); the tag and link calls themselves only run in the workflow
  • The token needs write:package and write:repository (README updated). If the job token lacks either, add a PACKAGE_TOKEN secret

🤖 Generated with Claude Code

The release workflow published the package but did not tag the commit or connect the package to this repository. `scripts/release.ts` now, after publishing: - creates the git tag `v<version>` on the workflow's commit via the Gitea API (skips if it exists) - links the package to this repository via `POST /packages/{owner}/npm/{name}/-/link/{repo}` (skips if the package already has a repository) Publishing, tagging and linking are each idempotent, so **starting the workflow again completes a release that already published but was never tagged or linked**. The workflow now passes `SERVER_URL`, `REPOSITORY` and `SHA` (replacing `REGISTRY_URL`). - 12 new tests with a fake Gitea API (42 total); `npm run check` passes - I checked read-only against git.arthurerlich.de that the tag lookup and the encoded scoped package path route correctly (404 JSON messages); the tag and link calls themselves only run in the workflow - The token needs `write:package` and `write:repository` (README updated). If the job token lacks either, add a `PACKAGE_TOKEN` secret 🤖 Generated with [Claude Code](https://claude.com/claude-code)
haylan added 1 commit 2026-10-03 18:44:10 +00:00
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
haylan merged commit f16536fffd into main 2026-10-03 18:46:00 +00:00
haylan deleted branch ci/tag-and-link-release 2026-10-03 18:46:01 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: haylan/fastcrw-opencode-websearch#18