@@ -145,7 +145,7 @@ jobs:
145
145
- name : Setup & Build
146
146
id : build
147
147
shell : bash
148
- timeout-minutes : 40
148
+ timeout-minutes : 80
149
149
env :
150
150
ARTIFACT_NAME : ${{ matrix.config.artifact }}
151
151
run : |
@@ -187,6 +187,7 @@ jobs:
187
187
throw new Error("Could not find node versions");
188
188
}
189
189
190
+ $.verbose = true;
190
191
await $`mkdir -p bins`;
191
192
192
193
async function buildBinary(arch, flags = [], nodeTarget = nodeVersion) {
@@ -253,28 +254,28 @@ jobs:
253
254
# unzip -d ./upx "./upxInstallations/upx-${UPX_VERSION}-win64.zip"
254
255
# mv "./upx/upx-${UPX_VERSION}-win64" ./upx/upx
255
256
#
256
- # ./upx/upx/upx.exe --best ./bins/win-x64-cuda/llama-addon.node
257
+ # ./upx/upx/upx.exe --best ./bins/win-x64-cuda/Release/ggml.dll
257
258
258
- - name : Compress CUDA binary on Ubuntu
259
- if : matrix.config.name == 'Ubuntu'
260
- env :
261
- UPX_VERSION : 4.2.4
262
- run : |
263
- mkdir -p upxInstallations
264
-
265
- if [ ! -f "./upxInstallations/upx-${UPX_VERSION}-amd64_linux.tar.xz" ]; then
266
- pushd upxInstallations
267
- curl -OL "https://github.com/upx/upx/releases/download/v${UPX_VERSION}/upx-${UPX_VERSION}-amd64_linux.tar.xz"
268
- popd
269
- fi
270
-
271
- mkdir -p upx
272
- tar -xvf "./upxInstallations/upx-${UPX_VERSION}-amd64_linux.tar.xz" -C ./upx
273
- mv "./upx/upx-${UPX_VERSION}-amd64_linux" ./upx/upx
274
-
275
- chmod +x ./bins/linux-x64-cuda/llama-addon.node
276
- ./upx/upx/upx --best ./bins/linux-x64-cuda/llama-addon.node
277
- chmod -x ./bins/linux-x64-cuda/llama-addon.node
259
+ # - name: Compress CUDA binary on Ubuntu
260
+ # if: matrix.config.name == 'Ubuntu'
261
+ # env:
262
+ # UPX_VERSION: 4.2.4
263
+ # run: |
264
+ # mkdir -p upxInstallations
265
+ #
266
+ # if [ ! -f "./upxInstallations/upx-${UPX_VERSION}-amd64_linux.tar.xz" ]; then
267
+ # pushd upxInstallations
268
+ # curl -OL "https://github.com/upx/upx/releases/download/v${UPX_VERSION}/upx-${UPX_VERSION}-amd64_linux.tar.xz"
269
+ # popd
270
+ # fi
271
+ #
272
+ # mkdir -p upx
273
+ # tar -xvf "./upxInstallations/upx-${UPX_VERSION}-amd64_linux.tar.xz" -C ./upx
274
+ # mv "./upx/upx-${UPX_VERSION}-amd64_linux" ./upx/upx
275
+ #
276
+ # chmod +x ./bins/linux-x64-cuda/llama-addon.node
277
+ # ./upx/upx/upx --best ./bins/linux-x64-cuda/libggml.so
278
+ # chmod -x ./bins/linux-x64-cuda/llama-addon.node
278
279
279
280
- name : Publish artifact
280
281
uses : actions/upload-artifact@v4
@@ -423,13 +424,21 @@ jobs:
423
424
424
425
echo "Built binaries:"
425
426
ls bins
427
+ - name : Move binaries to standalone prebuilt binary modules
428
+ run : npx --no vite-node ./scripts/movePrebuiltBinariesToStandaloneModules.ts
429
+ - name : Prepare standalone prebuilt binary modules
430
+ run : npx --no vite-node ./scripts/prepareStandalonePrebuiltBinaryModules.ts
426
431
- name : Add "postinstall" script to package.json
427
432
run : npm run addPostinstallScript
428
433
- name : Release
429
434
env :
430
435
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
431
436
NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
432
- run : npx semantic-release
437
+ GH_RELEASE_REF : ${{ github.ref }}
438
+ run : |
439
+ echo "//registry.npmjs.org/:_authToken=\${NPM_TOKEN}" > ~/.npmrc
440
+
441
+ npx semantic-release
433
442
- name : Set npm package url to GITHUB_OUTPUT
434
443
id : set-npm-url
435
444
run : |
0 commit comments