Fix node-gyp build on Windows (#2233)

* ONE MORE TIME

* I cant type

* try this

* I think I actually did it!
This commit is contained in:
Devin Binnie 2022-08-22 15:50:26 -04:00 committed by GitHub
parent 7d321e849b
commit 93b6eb4f9b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 6 deletions

View file

@ -191,8 +191,8 @@ jobs:
- run: - run:
name: Install nodejs-lts name: Install nodejs-lts
command: choco install nodejs-lts -y command: choco install nodejs-lts -y
# ignoring scripts for windows due to issues with node-gyp - run: npm i -g node-gyp; node-gyp install
- run: $env:PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = 1; npm ci --ignore-scripts - run: $env:PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = 1; npm ci
- build: - build:
os: windows os: windows
path: ./build/win path: ./build/win
@ -269,7 +269,8 @@ jobs:
- run: - run:
name: Install nodejs-lts name: Install nodejs-lts
command: choco install nodejs-lts -y command: choco install nodejs-lts -y
- run: $env:PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = 1; npm ci --ignore-scripts - run: npm i -g node-gyp; node-gyp install
- run: $env:PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = 1; npm ci
- build: - build:
os: windows os: windows
path: ./build/win path: ./build/win

1
package-lock.json generated
View file

@ -90,7 +90,6 @@
"mmjstool": "github:mattermost/mattermost-utilities#3b4506b0f6b14fbb402f9f8ef932370e459e3773", "mmjstool": "github:mattermost/mattermost-utilities#3b4506b0f6b14fbb402f9f8ef932370e459e3773",
"mocha-circleci-reporter": "0.0.3", "mocha-circleci-reporter": "0.0.3",
"mochawesome": "7.1.3", "mochawesome": "7.1.3",
"node-gyp": "9.0.0",
"node-loader": "2.0.0", "node-loader": "2.0.0",
"npm-run-all": "4.1.5", "npm-run-all": "4.1.5",
"playwright": "1.23.4", "playwright": "1.23.4",

View file

@ -172,7 +172,6 @@
"mmjstool": "github:mattermost/mattermost-utilities#3b4506b0f6b14fbb402f9f8ef932370e459e3773", "mmjstool": "github:mattermost/mattermost-utilities#3b4506b0f6b14fbb402f9f8ef932370e459e3773",
"mocha-circleci-reporter": "0.0.3", "mocha-circleci-reporter": "0.0.3",
"mochawesome": "7.1.3", "mochawesome": "7.1.3",
"node-gyp": "9.0.0",
"node-loader": "2.0.0", "node-loader": "2.0.0",
"npm-run-all": "4.1.5", "npm-run-all": "4.1.5",
"playwright": "1.23.4", "playwright": "1.23.4",

View file

@ -525,7 +525,9 @@ function Run-BuildChangelog {
function Run-BuildElectron { function Run-BuildElectron {
Print-Info "Installing nodejs/electron dependencies (running npm ci)..." Print-Info "Installing nodejs/electron dependencies (running npm ci)..."
npm ci --ignore-scripts npm i -g node-gyp
node-gyp install
npm ci
#npm install --prefix="$(Get-RootDir)" "$(Get-RootDir)" #npm install --prefix="$(Get-RootDir)" "$(Get-RootDir)"
Print-Info "Building nodejs/electron code (running npm run build)..." Print-Info "Building nodejs/electron code (running npm run build)..."
npm run build npm run build