updated github action #27
Workflow file for this run
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 App" | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
build: | |
name: Build application | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- os: ubuntu-20.04 | |
- os: windows-latest | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install linux dependencies | |
if: matrix.os =='ubuntu-20.04' | |
run: sudo apt-get install fuse libfuse2 libopengl0 libegl1 libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-shape0 libxcb-cursor0 | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Install dependencies | |
run: | | |
npm install | |
# - name: Set version | |
# run: | | |
# npm version --no-git-tag-version from-git | |
- name: Apply packer patch (upgrade linuxqtdeploy to continuous) | |
if: matrix.os =='ubuntu-20.04' | |
run: | | |
npm run patch | |
- name: Build application | |
run: | | |
npm run build | |
- name: Package application | |
run: | | |
echo $VERSION | |
npm run package | |
env: | |
VERSION: ${{ github.ref_name }} | |
- name: Upload artefact | |
if: matrix.os =='ubuntu-20.04' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: DeadbrainWallet-${{ github.ref_name }}-x86_64.AppImage | |
path: deploy/linux/build/DeadbrainWallet/DeadbrainWallet-${{ github.ref_name }}-x86_64.AppImage | |
- name: Install NSIS | |
if: matrix.os =='windows-latest' | |
run: | | |
iwr -useb get.scoop.sh -outfile 'install.ps1' | |
.\install.ps1 -RunAsAdmin | |
scoop update | |
scoop bucket add extras | |
scoop install nsis | |
- name: Print NSIS version | |
if: matrix.os =='windows-latest' | |
run: makensis -VERSION | |
# - name: Create archive (zip) | |
# if: matrix.os =='windows-latest' | |
# run: 7z a DeadbrainWallet-${{ github.ref_name }}.zip deploy\win32\build\DeadbrainWallet | |
- name: Create archive (zip) | |
if: matrix.os =='windows-latest' | |
run: makensis deadbrainwallet.nsi | |
- name: Upload artefact | |
if: matrix.os =='windows-latest' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: DeadbrainWallet_setup.exe | |
path: DeadbrainWallet_setup.exe | |
release: | |
name: Create release with assets | |
runs-on: ubuntu-latest | |
needs: [build] | |
steps: | |
- name: Download artefact (linux) | |
uses: actions/download-artifact@v4 | |
with: | |
name: DeadbrainWallet-${{ github.ref_name }}-x86_64.AppImage | |
- name: Download artefact (win32) | |
uses: actions/download-artifact@v4 | |
with: | |
name: DeadbrainWallet-${{ github.ref_name }}.zip | |
- run: ls | |
- name: Create release | |
uses: softprops/action-gh-release@v2 | |
with: | |
name: Release ${{ github.ref_name }} | |
files: | | |
DeadbrainWallet-${{ github.ref_name }}-x86_64.AppImage | |
DeadbrainWallet-${{ github.ref_name }}.zip | |
draft: true | |
generate_release_notes: true |