Skip to content

Commit 8854da8

Browse files
authored
Revert "Move repetitive build commands into environment variables (#989)"
This reverts commit c88ca6d.
1 parent c88ca6d commit 8854da8

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

.github/workflows/build.yml

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,6 @@ on:
1212
- released
1313
workflow_dispatch: {}
1414

15-
env:
16-
NODE_BUILD_CMD: npx --no-install prebuild -r node -t 14.0.0 -t 16.0.0 -t 18.0.0 --include-regex 'better_sqlite3.node$'
17-
ELECTRON_BUILD_CMD: npx --no-install prebuild -r electron -t 16.0.0 -t 17.0.0 -t 18.0.0 -t 19.0.0 -t 20.0.0 -t 21.0.0 -t 22.0.0 -t 23.0.0 -t 24.0.0 --include-regex 'better_sqlite3.node$'
18-
1915
jobs:
2016
test:
2117
strategy:
@@ -71,12 +67,12 @@ jobs:
7167
with:
7268
node-version: 16
7369
- run: npm install --ignore-scripts
74-
- run: ${{ NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}
75-
- run: ${{ ELECTRON_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}
70+
- run: npx --no-install prebuild -r node -t 14.0.0 -t 16.0.0 -t 18.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}
71+
- run: npx --no-install prebuild -r electron -t 16.0.0 -t 17.0.0 -t 18.0.0 -t 19.0.0 -t 20.0.0 -t 21.0.0 -t 22.0.0 -t 23.0.0 -t 24.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}
7672
- if: matrix.os == 'windows-2019'
77-
run: ${{ ELECTRON_BUILD_CMD }} --arch ia32 -u ${{ secrets.GITHUB_TOKEN }}
73+
run: npx --no-install prebuild -r electron -t 16.0.0 -t 17.0.0 -t 18.0.0 -t 19.0.0 -t 20.0.0 -t 21.0.0 -t 22.0.0 -t 23.0.0 -t 24.0.0 --include-regex 'better_sqlite3.node$' --arch ia32 -u ${{ secrets.GITHUB_TOKEN }}
7874
- if: matrix.os == 'macos-latest'
79-
run: ${{ ELECTRON_BUILD_CMD }} --arch arm64 -u ${{ secrets.GITHUB_TOKEN }}
75+
run: npx --no-install prebuild -r electron -t 16.0.0 -t 17.0.0 -t 18.0.0 -t 19.0.0 -t 20.0.0 -t 21.0.0 -t 22.0.0 -t 23.0.0 -t 24.0.0 --include-regex 'better_sqlite3.node$' --arch arm64 -u ${{ secrets.GITHUB_TOKEN }}
8076

8177
prebuild-alpine:
8278
name: Prebuild on alpine
@@ -87,7 +83,7 @@ jobs:
8783
- uses: actions/checkout@v3
8884
- run: apk add build-base git python3 --update-cache
8985
- run: npm install --ignore-scripts
90-
- run: ${{ NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}
86+
- run: npx --no-install prebuild -r node -t 14.0.0 -t 16.0.0 -t 18.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}
9187

9288
prebuild-alpine-arm:
9389
strategy:
@@ -106,7 +102,7 @@ jobs:
106102
apk add build-base git python3 --update-cache && \
107103
cd /tmp/project && \
108104
npm install --ignore-scripts && \
109-
${{ NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}"
105+
npx --no-install prebuild -r node -t 14.0.0 -t 16.0.0 -t 18.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}"
110106
111107
prebuild-linux-arm:
112108
strategy:
@@ -124,4 +120,4 @@ jobs:
124120
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:16 -c "\
125121
cd /tmp/project && \
126122
npm install --ignore-scripts && \
127-
${{ NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}"
123+
npx --no-install prebuild -r node -t 14.0.0 -t 16.0.0 -t 18.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}"

0 commit comments

Comments
 (0)