File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44 release :
55 types : [created]
66
7+ permissions :
8+ id-token : write
9+ contents : read
10+
711jobs :
812 build :
913 if : github.repository == 'my-mcp-hub/mcp-kit'
1014 runs-on : ubuntu-latest
11- permissions :
12- contents : read
13- id-token : write
1415 steps :
1516 - name : Get package name
1617 id : package
3637 - name : Test Package
3738 run : pnpm run test
3839
39- - name : Publish NPM Package
40- run : |
41- cd packages/$PACKAGE_NAME
42- pnpm publish --no-git-checks --provenance --access public
43- env :
44- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
40+ - name : Pack package
41+ run : pnpm -C packages/${{ env.PACKAGE_NAME }} pack
42+
43+ - name : Upload dist artifact
44+ uses : actions/upload-artifact@v6
45+ with :
46+ name : npm-package
47+ path : packages/${{ env.PACKAGE_NAME }}/*.tgz
48+
49+ # - name: Publish NPM Package
50+ # run: |
51+ # cd packages/$PACKAGE_NAME
52+ # pnpm publish --no-git-checks --provenance --access public
53+ # env:
54+ # NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
55+
56+ publish :
57+ if : github.repository == 'my-mcp-hub/mcp-kit'
58+ needs : build
59+ runs-on : ubuntu-latest
60+
61+ steps :
62+ - uses : actions/checkout@v6
63+
64+ - uses : actions/download-artifact@v7
65+ with :
66+ name : npm-package
67+ path : .
68+
69+ - uses : actions/setup-node@v6
70+ with :
71+ node-version : ' 24'
72+ registry-url : ' https://registry.npmjs.org'
73+ - run : npm publish *.tgz --no-git-checks --provenance --access public
You can’t perform that action at this time.
0 commit comments