Fix failing security tests #328
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build-checks | |
on: | |
push: | |
pull_request: | |
jobs: | |
build-web: | |
strategy: | |
matrix: | |
os: [ macos, ubuntu, windows ] | |
mode: [ development, test, production ] | |
fail-fast: false # Allows to see results from other combinations | |
runs-on: ${{ matrix.os }}-latest | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v2 | |
- | |
name: Setup node | |
uses: ./.github/actions/setup-node | |
- | |
name: Install dependencies | |
run: npm ci | |
- | |
name: Build | |
run: npm run build -- --mode ${{ matrix.mode }} | |
# A new job is used due to environments/modes different from Vue CLI, https://github.com/nklayman/vue-cli-plugin-electron-builder/issues/1626 | |
build-desktop: | |
strategy: | |
matrix: | |
os: [ macos, ubuntu, windows ] | |
mode: [ development, production ] # "test" is not supported https://github.com/nklayman/vue-cli-plugin-electron-builder/issues/1627 | |
fail-fast: false # Allows to see results from other combinations | |
runs-on: ${{ matrix.os }}-latest | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v2 | |
- | |
name: Setup node | |
uses: ./.github/actions/setup-node | |
- | |
name: Install dependencies | |
run: npm ci | |
- | |
name: Install cross-env | |
# Used to set NODE_ENV due to https://github.com/nklayman/vue-cli-plugin-electron-builder/issues/1626 | |
run: npm install --global cross-env | |
- | |
name: Build | |
run: |- | |
cross-env-shell NODE_ENV=${{ matrix.mode }} | |
npm run electron:build -- --publish never --mode ${{ matrix.mode }} | |
create-icons: | |
strategy: | |
matrix: | |
os: [ macos, ubuntu, windows ] | |
fail-fast: false # Allows to see results from other combinations | |
runs-on: ${{ matrix.os }}-latest | |
steps: | |
- | |
name: Checkout | |
uses: actions/checkout@v2 | |
- | |
name: Setup node | |
uses: ./.github/actions/setup-node | |
- | |
name: Install dependencies | |
run: npm ci | |
- | |
name: Create icons | |
run: npm run create-icons |