2019-09-25 23:28:15 +02:00
|
|
|
name: Build Windows Client
|
|
|
|
|
|
|
|
on: [push, pull_request]
|
|
|
|
|
|
|
|
jobs:
|
2019-10-05 21:15:34 +02:00
|
|
|
build_win:
|
2019-09-25 23:28:15 +02:00
|
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
|
|
- name: Clone source code
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: Use Node.js
|
|
|
|
uses: actions/setup-node@v1
|
|
|
|
with:
|
|
|
|
node-version: 10.x
|
2019-12-23 20:03:56 +01:00
|
|
|
- name: Change desktop field
|
2019-12-23 17:50:59 +01:00
|
|
|
run: |
|
2019-12-23 20:03:56 +01:00
|
|
|
from json import load, dump
|
|
|
|
|
|
|
|
json_dict = {}
|
|
|
|
with open('public/config.json', 'r') as file:
|
|
|
|
json_dict = load(file)
|
|
|
|
|
|
|
|
json_dict["location"] = "desktop"
|
|
|
|
|
|
|
|
with open('public/config.json', 'w+') as out:
|
|
|
|
dump(json_dict, out)
|
|
|
|
shell: python
|
2019-09-25 23:28:15 +02:00
|
|
|
- name: Install dependencies and build
|
|
|
|
run: |
|
|
|
|
npm install
|
|
|
|
npm run build --if-present
|
2019-12-23 17:39:20 +01:00
|
|
|
npm run build-desktop-win
|
|
|
|
- name: Upload Windows executable
|
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
if: success()
|
|
|
|
with:
|
2019-12-23 17:50:59 +01:00
|
|
|
name: 'Windows executable (output dir)'
|
|
|
|
path: dist
|