Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .github/workflows/jsr-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Sync version to jsr.jsonc
run: |
node -e "
Comment thread
antongolub marked this conversation as resolved.
Outdated
const fs = require('fs');
const pkgVersion = require('./package.json').version;
let text = fs.readFileSync('jsr.jsonc', 'utf8');

text = text.replace(
/(\"version\"\s*:\s*\")([^\"]+)(\")/,
\`$1\${pkgVersion}$3\`
Comment thread
antongolub marked this conversation as resolved.
Outdated
);

fs.writeFileSync('jsr.jsonc', text);
"
- run: npx jsr publish