GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — ci: move the npm latest tag from a workflow, and after every release by jasdeepkhalsa · Pull Request #263 · DBDiff/DBDiff

Conversation

@jasdeepkhalsa

@jasdeepkhalsa jasdeepkhalsa commented Oct 11, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Pre-releases publish to npm under their own tag (rc), so npm install @dbdiff/cli kept resolving to an older version until latest was moved by hand.

New: npm-dist-tag.yml (Actions → Move npm dist-tag → Run workflow)

  • Inputs: a published version and a tag (default latest).
  • Moves the tag on @dbdiff/cli and all eight platform packages together. Platform packages go first and the root last, since the root is what people install.
  • The move itself runs scripts/npm-promote-latest.sh, the script already used to move tags locally. Before touching anything it checks every package has that version on npmjs.org. If any is missing, nothing moves.
  • Before a stable release: latest can point at any pre-release.
  • After a stable release: latest only follows stable releases. It refuses a pre-release, and refuses a stable version older than the current latest (e.g. a 3.0.x patch after 3.1.0).
  • Other tags (rc, beta, …) can be moved freely.

Release integration

  • release.yml gains an npm-latest job that calls the same workflow after publish-npm.
  • When the guard refuses, it skips with a notice rather than failing the release. Run by hand, a refusal is an error.

Verified

  • actionlint passes on both files.
  • The guard was run locally against the live registry and a stubbed one. Each case gave the expected result:
Case Result
rc → latest, no stable yet moves
v-prefixed version refused
rc → rc moves
rc → latest after a stable exists refused (skipped when called from release)
older stable refused
newer stable moves
a version not fully published nothing moved

It needs the existing NPM_TOKEN secret, which already has write access to all nine packages.

🤖 Generated with Claude Code

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@jasdeepkhalsa @claude
ci: move the npm latest tag from a workflow, and after every release
2d61c2d
npm-dist-tag.yml points a dist-tag at a published version on @dbdiff/cli
and every platform package together. It runs by hand or from release.yml.
Until a stable release exists, latest follows each pre-release; after that
it only follows stable releases and never moves backwards.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions github-actions Bot added the bug label Oct 11, 2026
@jasdeepkhalsa @claude
ci: move the tag with the existing promote script
0f618a2
Co-Authored-By: Claude Opus 5.5 <[email protected]>
@sonarqubecloud

sonarqubecloud Bot commented Oct 11, 2026

Copy link
Copy Markdown

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jasdeepkhalsa
jasdeepkhalsa merged commit 25eefa4 into master Oct 12, 2026
77 checks passed

Uh oh!

There was an error while loading. Please reload this page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

bug

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@jasdeepkhalsa
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.