You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
chore(ci): update publish workflow for CLI package
- Modified tag pattern to allow for all version tags (v*.*.*) during publishing.
- Updated Node.js version from 20 to 24 in the setup step.
- Added verification steps for the release environment, ensuring Node.js and npm versions meet the required thresholds.
- Implemented checks to verify that the tag commit is on the main branch and that the version is not already published.
- Removed provenance flag from npm publish command for a cleaner publish process.
node -e "const version = process.argv[1]; if (!/^\\d+\\.\\d+\\.\\d+$/.test(version)) throw new Error('Official CLI releases must use a stable semver version')" "$version"
38
49
test "v${version}" = "${GITHUB_REF_NAME}"
50
+
echo "CLI_VERSION=${version}" >> "$GITHUB_ENV"
51
+
52
+
- name: Verify version is not already published
53
+
run: |
54
+
if npm view "@markdown-ai/cli@${CLI_VERSION}" version --registry https://registry.npmjs.org >/dev/null 2>&1; then
55
+
echo "@markdown-ai/cli@${CLI_VERSION} is already published"
56
+
exit 1
57
+
fi
39
58
40
59
- run: pnpm cli:test
41
60
61
+
- run: pnpm -C apps/cli smoke:package
62
+
42
63
- run: npm pack --dry-run --json
43
64
working-directory: apps/cli
44
65
45
-
- run: npm publish --provenance --access public --tag rc
0 commit comments