I am developing a desktop app on a Linux machine. The code is hosted on GitLab.com. I'd like a sample gitlab-ci.yml on building the app for Windows. I'm out of ideas on how to go about this, any assistance will be appreciated.
The build steps depends on the library you are using to build the electron app. Here is a sample using electron-builder
// .gitlab-ci.yml
stages:
- build
build:
image: electronuserland/builder:wine
stage: build
script:
- yarn
- yarn dist:win
artifacts:
expire_in: 30 days
paths:
- ./dist/
only:
- master
// package.json
{
...
"scripts": {
...
"dist:win": "electron-builder -w",
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With