name: Build/PROJECT on: push: #tags: #- '*' jobs: build_release: name: Build release runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] include: - os: ubuntu-latest zip_name: ubuntu_tnc generator: Unix Makefiles #- os: macos-latest # zip_name: plugin-mac # generator: Xcode #- os: windows-latest # zip_name: plugin-win # generator: Visual Studio 16 2019 steps: - name: Checkout code uses: actions/checkout@v2 - name: Set up Python 3.8 uses: actions/setup-python@v2 with: python-version: 3.8 - name: Install Linux dependencies if: matrix.os == 'ubuntu-latest' run: | sudo apt install portaudio19-dev build-essential cmake python -m pip install --upgrade pip pip3 install pyaudio pip3 install psutil pip3 install crcengine pip3 install pyinstaller pip3 install ujson - name: Build Linux if: matrix.os == 'ubuntu-latest' working-directory: tnc run: | pyinstaller -F daemon.py -n daemon pyinstaller -F main.py -n tnc - name: Build codec2 Linux if: matrix.os == 'ubuntu-latest' # working-directory: tnc run: | cd ~ git clone https://github.com/drowe67/codec2.git cd codec2 && mkdir build_linux && cd build_linux cmake ../ make - name: Build LPCNet Linux if: matrix.os == 'ubuntu-latest' # working-directory: tnc run: | cd ~ git clone https://github.com/drowe67/LPCNet cd LPCNet && mkdir build_linux && cd build_linux cmake -DCODEC2_BUILD_DIR=~/codec2/build_linux ../ make - name: ReBuild codec2 with LPCNet Linux if: matrix.os == 'ubuntu-latest' # working-directory: tnc run: | cd ~/codec2/build_linux && rm -Rf * cmake -DLPCNET_BUILD_DIR=~/LPCNet/build_linux .. make - name: LIST ALL FILES shell: bash run: | ls -R - name: Copy codec2 to TNC Linux if: matrix.os == 'ubuntu-latest' # working-directory: tnc run: | cp -R ~/codec2 ./tnc/dist ls -R - name: Compress Linux shell: bash run: | cd ./tnc/dist mkdir compressed zip -r ./compressed/${{ matrix.zip_name }}.zip * - name: Upload Ubuntu TNC artifacts uses: actions/upload-artifact@v2 with: name: tnc-artifact path: ./tnc/dist/compressed/* - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v1 with: node-version: 14 - name: Copy TNC to GUI Linux if: matrix.os == 'ubuntu-latest' # working-directory: tnc run: | cp -R ./tnc/dist ./gui/tnc ls -R - name: Build/release Electron app uses: samuelmeuli/action-electron-builder@v1 with: package_root: "./gui/" github_token: ${{ secrets.github_token }} - name: LIST ALL FILES shell: bash run: | ls -R - name: chmod +x shell: bash run: | chmod +x ./gui/dist/*.AppImage - name: Create app bundle shell: bash run: | mkdir gui-bundle cp ./gui/dist/*.AppImage gui-bundle cp -R ./tnc/dist gui-bundle cd ./gui-bundle zip -r codec2-FreeDATA_ubuntu.zip . - name: Upload Ubuntu GUI Bundle artifacts uses: actions/upload-artifact@v2 with: name: gui-bundle-ubuntu-artifact #path: ./gui/dist/*.AppImage #path: ./gui/dist/* path: ./gui/dist/codec2-FreeDATA_ubuntu.zip release: name: Upload Release needs: build_release runs-on: ubuntu-latest steps: - name: Download artifact uses: actions/download-artifact@v2 - name: LIST ALL FILES shell: bash run: | ls -R - name: Release uses: softprops/action-gh-release@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: #upload_url: ${{ needs.create_release.outputs.upload_url }} #asset_path: ./tnc/compressed/${{ matrix.zip_name }}.zip #asset_name: ${{ matrix.zip_name }}.zip #asset_content_type: application/zip files: | ./tnc/compressed/${{ matrix.zip_name }}.zip LICENSE