2323 - run : deno task test --coverage=.cov --junit-path=.test-report.xml
2424 env :
2525 RUST_BACKTRACE : ${{ runner.debug }}
26+ LOG : ${{ runner.debug && 'always' || '' }}
2627 working-directory : ${{ github.workspace }}/fedify/
2728 - uses : dorny/test-reporter@v2
2829 if : success() || failure()
4647 continue-on-error : true
4748 - run : " true"
4849
49- test-dnt :
50+ test-node :
51+ strategy :
52+ matrix :
53+ os : [macos-latest, ubuntu-latest, windows-latest]
54+ fail-fast : false
55+ runs-on : ${{ matrix.os }}
56+ steps :
57+ - uses : actions/checkout@v4
58+ - uses : denoland/setup-deno@v2
59+ with :
60+ deno-version : v2.x
61+ - uses : actions/setup-node@v4
62+ with :
63+ node-version : lts/*
64+ - uses : pnpm/action-setup@v4
65+ with :
66+ version : 10
67+ - run : deno task test:node
68+ working-directory : ${{ github.workspace }}/fedify/
69+
70+ test-bun :
5071 strategy :
5172 matrix :
5273 os : [macos-latest, ubuntu-latest, windows-latest]
@@ -63,12 +84,11 @@ jobs:
6384 - uses : oven-sh/setup-bun@v1
6485 with :
6586 bun-version : latest
66- - run : deno task cache
67- working-directory : ${{ github.workspace }}/fedify/
68- - run : deno task dnt
87+ - uses : pnpm/action-setup@v4
88+ with :
89+ version : 10
90+ - run : deno task test:bun
6991 working-directory : ${{ github.workspace }}/fedify/
70- - run : bun test_runner.js
71- working-directory : ${{ github.workspace }}/fedify/npm/
7292
7393 lint :
7494 runs-on : ubuntu-latest
@@ -92,19 +112,24 @@ jobs:
92112 - uses : actions/setup-node@v4
93113 with :
94114 node-version : lts/*
115+ - uses : pnpm/action-setup@v4
116+ with :
117+ version : 10
118+ - run : ' [[ "$(jq -r .version deno.json)" = "$(jq -r .version package.json)" ]]'
119+ working-directory : ${{ github.workspace }}/fedify/
95120 - run : deno task publish --dry-run
96121 working-directory : ${{ github.workspace }}/fedify/
97- - run : deno task dnt
122+ - run : deno task npm
123+ working-directory : ${{ github.workspace }}/fedify/
124+ - run : npm publish --dry-run fedify-fedify-*.tgz
98125 working-directory : ${{ github.workspace }}/fedify/
99- - run : npm publish --dry-run
100- working-directory : ${{ github.workspace }}/fedify/npm/
101126 env :
102127 DNT_SKIP_TEST : " true"
103128 - run : deno task publish-dry-run
104129 working-directory : ${{ github.workspace }}/cli/
105130
106131 publish :
107- needs : [test, test-dnt , lint, release-test]
132+ needs : [test, test-node, test-bun , lint, release-test]
108133 runs-on : ubuntu-latest
109134 permissions :
110135 id-token : write
@@ -117,6 +142,9 @@ jobs:
117142 - uses : actions/setup-node@v4
118143 with :
119144 node-version : lts/*
145+ - uses : pnpm/action-setup@v4
146+ with :
147+ version : 10
120148 - if : github.ref_type == 'branch'
121149 run : |
122150 jq \
@@ -136,12 +164,8 @@ jobs:
136164 # in deno.json:
137165 - run : rm vocab/.gitignore
138166 working-directory : ${{ github.workspace }}/fedify/
139- - run : ' deno task dnt "$(jq -r .version deno.json)" '
167+ - run : deno task npm
140168 working-directory : ${{ github.workspace }}/fedify/
141- env :
142- DNT_SKIP_TEST : " true"
143- - run : npm pack
144- working-directory : ${{ github.workspace }}/fedify/npm/
145169 - run : deno task pack
146170 working-directory : ${{ github.workspace }}/cli/
147171 - run : ' deno task npm "$(jq -r .version deno.json)"'
@@ -161,15 +185,15 @@ jobs:
161185 with :
162186 name : dist
163187 path : |
164- fedify/npm/ *.tgz
188+ fedify/fedify-fedify- *.tgz
165189 cli/fedify-cli-*
166190 - if : github.event_name == 'push' && github.ref_type == 'tag'
167191 uses : softprops/action-gh-release@v1
168192 with :
169193 body_path : ${{ steps.extract-changelog.outputs.output-file }}
170194 name : Fedify ${{ github.ref_name }}
171195 files : |
172- fedify/npm/ *.tgz
196+ fedify/fedify-fedify- *.tgz
173197 cli/fedify-cli-*
174198 generate_release_notes : false
175199 - if : |
@@ -189,13 +213,13 @@ jobs:
189213 set -ex
190214 npm config set //registry.npmjs.org/:_authToken "$NPM_AUTH_TOKEN"
191215 if [[ "$GITHUB_REF_TYPE" = "tag" ]]; then
192- npm publish --provenance --access public *.tgz
216+ npm publish --provenance --access public fedify-fedify- *.tgz
193217 else
194- npm publish --provenance --access public --tag dev *.tgz
218+ npm publish --provenance --access public --tag dev fedify-fedify- *.tgz
195219 fi
196220 env:
197221 NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
198- working-directory: ${{ github.workspace }}/fedify/npm/
222+ working-directory: ${{ github.workspace }}/fedify/
199223 - if : github.event_name == 'push' && github.ref_type == 'tag'
200224 run : |
201225 set -ex
0 commit comments