Skip to content

Update build.yml to create releases #54

Update build.yml to create releases

Update build.yml to create releases #54

Workflow file for this run

name: Build, package and test
on:
push:
branches:
- main
#workflow_dispatch:
#pull_request:
# branches:
# - master
#schedule:
# - cron: '0 4 * * *' # Runs every day at 4am: https://docs.github.com/en/actions/reference/events-that-trigger-workflows#scheduled-events-schedule
jobs:
build:
name: ${{ matrix.os }}, Node.js v${{ matrix.node }}
strategy:
fail-fast: false
matrix:
#os: [windows-2019, ubuntu-latest, macos-11]
os: [windows-2019, ubuntu-latest]
node: ['16.x']
runs-on: ${{ matrix.os }}
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0 # To fetch all history for all branches and tags. (Will be required for caching with lerna: https://github.com/markuplint/markuplint/pull/111)
- name: Use Node.js ${{ matrix.node }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
registry-url: 'https://registry.npmjs.org'
- name: Use Python 3.x
uses: actions/setup-python@v4
with:
python-version: '3.10.8'
- name: Build and package
shell: bash
run: |
yarn --skip-integrity-check --network-timeout 100000
yarn build
yarn download:plugins
yarn package:applications:prod
yarn add jszip pino pino-pretty -W
yarn eos package
mkdir applications/electron/dist/uploads
mv applications/electron/dist/EosThesisIDE.* applications/electron/dist/uploads
(test -e "applications/electron/dist/uploads/EosThesisIDE.exe.blockmap" && rm applications/electron/dist/uploads/EosThesisIDE.exe.blockmap) || true
env:
NODE_OPTIONS: --max_old_space_size=4096
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # https://github.com/microsoft/vscode-ripgrep/issues/9
- name: Upload artifacts to workflow action
uses: actions/upload-artifact@v2
with:
name: dist
path: applications/electron/dist/uploads
#- name: Test (Linux)
# if: matrix.tests != 'skip' && runner.os == 'Linux'
# uses: GabrielBB/xvfb-action@v1
# with:
# run: yarn electron test
#- name: Test (Windows)
# if: matrix.tests != 'skip' && runner.os == 'Windows'
# shell: bash
# run: |
# yarn electron test
#- name: Test (macOS)
# if: matrix.tests != 'skip' && runner.os == 'macOS'
# shell: bash
# run: |
# yarn electron test
#- name: Lint
# if: matrix.tests != 'skip'
# shell: bash
# run: |
# yarn lint