-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
2 changed files
with
38 additions
and
32 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: CI/CD For QLCTracker | ||
on: [push, pull_request] | ||
jobs: | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Use Node 12.x | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: '12.x' | ||
- name: Install dependencies | ||
run: npm i | ||
- name: Build Web Version | ||
run: npm run qlc:build | ||
- name: Archive build | ||
if: success() | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: deploy_dist | ||
path: dist | ||
- name: Build Electron app | ||
uses: samuelmeuli/action-electron-builder@v1 | ||
with: | ||
# GitHub token, automatically provided to the action | ||
# (No need to define this secret in the repo settings) | ||
github_token: ${{ secrets.github_token }} | ||
|
||
build_script_name: qlc:build-desktop | ||
# macOS code signing certificate | ||
mac_certs: ${{ secrets.mac_certs }} | ||
mac_certs_password: ${{ secrets.mac_certs_password }} | ||
|
||
# If the commit is tagged with a version (e.g. "v1.0.0"), | ||
# release the app after building | ||
release: ${{ startsWith(github.ref, 'refs/tags/v') }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +0,0 @@ | ||
matrix: | ||
include: | ||
- os: osx | ||
osx_image: xcode10.2 | ||
language: node_js | ||
node_js: "10" | ||
env: | ||
- ELECTRON_CACHE=$HOME/.cache/electron | ||
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder | ||
|
||
cache: | ||
directories: | ||
- node_modules | ||
- $HOME/.cache/electron | ||
- $HOME/.cache/electron-builder | ||
|
||
script: | ||
- | | ||
if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then | ||
echo $CERTIFICATE_OSX_P12 | base64 --decode > keystore.p12; | ||
security create-keychain -p $KEYCHAIN_PASSWORD build.keychain; | ||
security default-keychain -s build.keychain; | ||
security unlock-keychain -p $KEYCHAIN_PASSWORD build.keychain; | ||
security import keystore.p12 -k build.keychain -P $KEYCHAIN_PASSWORD -T /usr/bin/codesign; | ||
security set-key-partition-list -S apple-tool:,apple: -s -k $KEYCHAIN_PASSWORD build.keychain; | ||
npm install; | ||
npm run qlc:build-desktop-high-mem; | ||
npm run desktop:full; | ||
fi | ||
before_cache: | ||
- rm -rf $HOME/.cache/electron-builder/wine | ||