Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 0 additions & 37 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,40 +35,3 @@ jobs:

- name: Test
run: npm test

publish-next:
name: Publish @next
needs: [quality-gate]
if: github.event_name == 'push' && github.ref == 'refs/heads/dev'
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Build
run: npm run build

- name: Publish to npm @next
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
if [ -z "$NODE_AUTH_TOKEN" ]; then
echo "NPM_TOKEN not set — skipping @next publish"
exit 0
fi
echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > ~/.npmrc
LOCAL=$(jq -r '.version' package.json)
PUBLISHED=$(npm view @automagik/rlmx@next version 2>/dev/null || echo "none")
if [ "$LOCAL" = "$PUBLISHED" ]; then
echo "Version $LOCAL already published to @next — skipping"
exit 0
fi
npm publish --tag next --access public || echo "Publish failed (version may already exist) — non-fatal"
33 changes: 0 additions & 33 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,36 +84,3 @@ jobs:
--title "${TAG}" \
--notes-file /tmp/release-notes.md
fi
Comment on lines 84 to 86
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Keep npm publish in release hotfix/manual path

After this change, the Release job ends immediately after gh release create, so manual runs (or any run where Resolve version derives a hotfix tag) now create a GitHub release without publishing the matching npm version. This is a regression from the previous workflow behavior and can leave v<version> tags discoverable in GitHub with no corresponding package on npm. version.yml does not backfill this path because its manual trigger publishes from dev (branch || 'dev') and its main publish path is gated to CI workflow_run merge commits from /dev.

Useful? React with 👍 / 👎.


- uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Patch version for hotfix
if: steps.ver.outputs.hotfix == 'true'
run: |
VERSION="${{ steps.ver.outputs.version }}"
jq --arg v "$VERSION" '.version = $v' package.json > package.json.tmp
mv package.json.tmp package.json

- name: Build
run: npm run build

- name: Publish to npm
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
if [ -z "$NODE_AUTH_TOKEN" ]; then
echo "ERROR: NPM_TOKEN secret is not set." >&2
exit 1
fi
echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > ~/.npmrc
VERSION="${{ steps.ver.outputs.version }}"
if ! npm publish --access public 2>&1; then
echo "Publish failed — retagging as latest..."
npm dist-tag add "@automagik/rlmx@${VERSION}" latest
fi
Loading