ci(build): 💚 Hopefully fix deployment CI

This commit is contained in:
Jesse Wierzbinski 2024-06-07 22:52:48 -10:00
parent 028915f6c6
commit d01ed19a66
No known key found for this signature in database

View file

@ -39,14 +39,10 @@ jobs:
- uses: oven-sh/setup-bun@v1
- name: Create bunfig.toml with NPM token (GitHub Secrets)
run: echo -e "[install]\nregistry = { url = \"https://registry.npmjs.org/\", token = \"${{ secrets.NPM_TOKEN }}\" }" > bunfig.toml
- name: Copy bunfig.toml to package directory
run: cp bunfig.toml ${{ github.event.inputs.package }}/bunfig.toml
- name: Install dependencies
run: bun install --frozen-lockfile
- uses: actions/setup-node@v4
with:
node-version: "22"
registry-url: "https://registry.npmjs.org"
# Code is not minified and bundled anymore
#- name: Build
@ -55,14 +51,10 @@ jobs:
- name: Change version in package.json to ${{ github.event.inputs.version }}, defaulting to the truncated commit hash
run: 'sed -i ''s/"version": ".*"/"version": "${{ github.event.inputs.version }}"/'' package.json ${{ github.event.inputs.package }}/package.json ${{ github.event.inputs.package }}/jsr.jsonc'
- name: CD to package directory
run: cd ${{ github.event.inputs.package }} && bun install --frozen-lockfile
- name: Patch Bunpublish to not break
run: sed -i --follow-symlinks 's/getHeapStatistics().heap_size_limit/99999999/g' "node_modules/@npmcli/arborist/lib/packument-cache.js"
- name: Publish to NPM
run: cd ${{ github.event.inputs.package }} && bunx @morlay/bunpublish --provenance --tag ${{ github.event.inputs.tag }}
run: cd ${{ github.event.inputs.package }} && npm publish --provenance --tag ${{ github.event.inputs.tag }} --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish to JSR
run: cd ${{ github.event.inputs.package }} && bunx jsr publish --allow-slow-types --allow-dirty