-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (42 loc) · 1.22 KB
/
build.yml
File metadata and controls
49 lines (42 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Build and Publish to jsr
on:
release:
types: [published]
permissions:
id-token: write
contents: read
jobs:
build:
runs-on: blacksmith-4vcpu-ubuntu-2204
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.FLOWCORE_MACHINE_GITHUB_TOKEN }}
submodules: true
- name: Extract version from deno.json
uses: sergeysova/jq-action@v2
id: version
with:
cmd: "jq .version deno.json -r"
- name: Show my version
run: 'echo "version ${{ steps.version.outputs.value }}"'
- name: Setup Deno2 environment
uses: denoland/setup-deno@v2
with:
deno-version: v2.x
- name: Deno install
run: deno install --frozen-lockfile
- name: Lint
run: deno lint
- name: Publish to JSR
run: deno publish
- name: Build for NPM
run: deno run -A bin/build-npm.ts
- uses: useblacksmith/setup-node@v5
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
- name: Update npm to latest
run: npm install -g npm@latest
- name: Publish to NPM
run: cd npm && npm publish --access public --provenance=false