Skip to content

Commit daa47a5

Browse files
ondreianclaude
andauthored
feat: add npm publishing to release workflow (#3)
- Rename job from zip-and-upload to publish-and-upload - Add npm publishing step with NPM_TOKEN secret - Update package name from @elanthia/cartograph to @elanthia/cartographer - Maintain existing GitHub release upload functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-authored-by: Claude <[email protected]>
1 parent 69c43bc commit daa47a5

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

.github/workflows/release-please.yaml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
# `MY_RELEASE_PLEASE_TOKEN` (this secret name is not important).
2626
token: ${{ secrets.GITHUB_TOKEN }}
2727
config-file: config/release-please.json
28-
zip-and-upload:
28+
publish-and-upload:
2929
if: needs.release-please.outputs.release_created == 'true'
3030
needs: release-please
3131
runs-on: ubuntu-latest
@@ -34,10 +34,21 @@ jobs:
3434
- uses: actions/checkout@v3
3535
with:
3636
ref: ${{ needs.release-please.outputs.tag_name }}
37+
3738
- uses: oven-sh/setup-bun@v1
39+
3840
- run: bun install
41+
3942
- run: bun run compile
40-
- name: upload-github-release
43+
44+
- name: Publish to npm
45+
run: |
46+
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
47+
bun publish --access public
48+
env:
49+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
50+
51+
- name: Upload binary to GitHub release
4152
env:
4253
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4354
run: |

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@elanthia/cartograph",
2+
"name": "@elanthia/cartographer",
33
"module": "mapdb/index.ts",
44
"version": "0.2.0",
55
"files": [

0 commit comments

Comments
 (0)