@nestjs-mcp/server 0.1.0-alpha.4 → 0.1.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/codeql-analysis.yml +3 -1
- package/.github/workflows/npm-publish.yml +3 -21
- package/.husky/pre-commit +8 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +18 -15
- package/scripts/npm-publish.js +67 -184
- package/.github/workflows/auto-tag-release.yml +0 -84
|
@@ -4,7 +4,6 @@ on:
|
|
|
4
4
|
push:
|
|
5
5
|
tags:
|
|
6
6
|
- 'v*'
|
|
7
|
-
- '*.*.*' # Also trigger on tags without 'v' prefix
|
|
8
7
|
|
|
9
8
|
jobs:
|
|
10
9
|
build-and-publish:
|
|
@@ -32,27 +31,10 @@ jobs:
|
|
|
32
31
|
- name: Build package
|
|
33
32
|
run: pnpm run build
|
|
34
33
|
|
|
35
|
-
- name: Ensure tag matches package.json version
|
|
36
|
-
run: |
|
|
37
|
-
TAG_VERSION=${GITHUB_REF#refs/tags/v}
|
|
38
|
-
PKG_VERSION=$(node -p "require('./package.json').version")
|
|
39
|
-
if [ "$TAG_VERSION" != "$PKG_VERSION" ]; then
|
|
40
|
-
echo "Tag version ($TAG_VERSION) does not match package.json version ($PKG_VERSION)."
|
|
41
|
-
exit 1
|
|
42
|
-
fi
|
|
43
|
-
|
|
44
|
-
- name: Ensure tag is on main (for latest only)
|
|
45
|
-
if: startsWith(github.ref, 'refs/tags/v') && !contains(github.ref, '-')
|
|
46
|
-
run: |
|
|
47
|
-
TAG_COMMIT=$(git rev-list -n 1 ${{ github.ref }})
|
|
48
|
-
MAIN_COMMIT=$(git rev-parse origin/main)
|
|
49
|
-
if [ "$TAG_COMMIT" != "$MAIN_COMMIT" ]; then
|
|
50
|
-
echo "Tag is not on main. Aborting publish as latest."
|
|
51
|
-
exit 1
|
|
52
|
-
fi
|
|
53
|
-
|
|
54
34
|
- name: Publish to NPM (with validations)
|
|
55
|
-
run:
|
|
35
|
+
run: |
|
|
36
|
+
TAG_NAME=${GITHUB_REF#refs/tags/}
|
|
37
|
+
pnpm exec node scripts/npm-publish.js --tag=$TAG_NAME --no-dry-run
|
|
56
38
|
env:
|
|
57
39
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
58
40
|
CI: true
|