Skip to content

Commit

Permalink
Publish
Browse files Browse the repository at this point in the history
  • Loading branch information
kla committed Dec 24, 2023
1 parent 0f4d9cf commit 133d1d7
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 3 deletions.
1 change: 0 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,4 @@ jobs:
- uses: actions/checkout@v3
- uses: oven-sh/setup-bun@v1
- run: bin/setup
- run: node --version
- run: bin/test
40 changes: 40 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: "Create Release"
on:
workflow_dispatch:
inputs:
version:
description: Version Number
required: true
jobs:
package:
name: Package
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3 # bun doesn't support publishing yet
with:
node-version-file: '.node-version'
- uses: oven-sh/setup-bun@v1
- run: bin/setup
- run: node --version
- run: echo "//npm.pkg.github.com/:_authToken=${{ secrets.DIGITS_NPM_TOKEN }}" >> ~/.npmrc
- env:
NODE_AUTH_TOKEN: ${{ secrets.DIGITS_NPM_TOKEN }}
run: echo $NODE_AUTH_TOKEN | wc -m
- env:
NODE_AUTH_TOKEN: ${{ secrets.DIGITS_NPM_TOKEN }}
run: ls -la ~ && cat ~/.npmrc && bin/publish
release:
name: Release
needs: package
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
- uses: ncipollo/release-action@v1
with:
tag: v${{ github.event.inputs.version }}
1 change: 1 addition & 0 deletions .node-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20.10.0
2 changes: 1 addition & 1 deletion bin/publish
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
set -e
bin/build
bun run publish
npm publish
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"name": "Kien La",
"email": "[email protected]"
},
"version": "0.6.0",
"version": "0.6.1",
"repository": "https://github.com/kla/digits",
"type": "module",
"main": "./dist/digits.umd.mjs",
Expand Down

0 comments on commit 133d1d7

Please sign in to comment.