feat(ci): publish tagged builds to the Forgejo npm registry; point the updater at it #12
No reviewers
Labels
No labels
area/dsh
area/forgejo
experiment
priority/later
priority/next
priority/now
type/bug
type/task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
dsh-plugins/dsh-gitea!12
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/ci-publish"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
One feature branch for the new release path and the updater repoint.
What changed
lib/plugin-updater.jsnow reads the Forgejo registry packument'sdist-tags.latest(Forgejo 17 does not serve npmjs's/latestalias), resolves the credential-backed token per request, and installs through a throwaway scoped.npmrc. That keeps@goodandreadyonhttps://git.pvlb.dev/api/packages/dsh-plugins/npm/while runtime deps and DSH peers still come from npmjs. The user's~/.npmrcis carried into the temp config so supply-chain settings survive..forgejo/workflows/ci.ymlrunsnpm run checkandnpm pack --dry-runon every push tomaster. Nopull_requesttrigger: the shared runner exposes the host Docker socket..forgejo/workflows/publish.ymlruns onv*tags, requires the tag to equalv<package.json version>, and publishes to the Forgejo npm registry withNPM_TOKEN(already added,write:package). Duplicate versions are skipped; manual runs are dry runs.README.ru.md/README.zh.mdremoved from the tree,package.json#files, and the leak scan.README.mdis the single README.0.7.40-dsh.3and CHANGELOG entry.Verification
npm run check: 37 tests pass, leak scan clean,node --checkclean.npm pack --dry-run: 95 files, 170.6 kB, version0.7.40-dsh.3; no translations/tests in the tarball.@goodandready/dsh-gitea-ci-probe@0.0.0published and was deleted via the API;latestVersion('dsh-resend-mcp')against the real registry returned0.1.2; packument auth withAuthorization: token …works.NPM_TOKENActions secret exists.Fixes #2 #5 #7 were already delivered in #11; this PR is the release/update path.
Follow-up after merge: the first publish run failed with
EPRIVATEbecausenpm pkg set private=falsestores the string"false"(truthy to npm). Fixed in95e0879withnpm pkg delete private; thev0.7.40-dsh.3tag was re-pointed to that commit (the failed run had published nothing).@goodandready/dsh-gitea@0.7.40-dsh.3is in the Forgejo registry (dist-tags.latest).latestVersion('@goodandready/dsh-gitea')returns0.7.40-dsh.3.The deployment profile still has
updates: falsefor thelink:dev checkout; flip it in Settings → Gitea when you want the in-UI updater active.