name: Build/PROJECT on: push: #tags: # - '*' jobs: create_release: name: Create release outputs: upload_url: ${{ steps.create_release.outputs.upload_url }} steps: - name: Create release id: create_release uses: softprops/action-gh-release@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: tag_name: ${{ github.ref }} release_name: ${{ github.ref }} draft: false prerelease: false build_release: name: Build release needs: create_release runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] include: - os: ubuntu-latest zip_name: ubuntu_tnc_$(date +'%Y-%m-%dT%H:%M:%S') 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 python -m pip install --upgrade pip pip3 install pyaudio pip3 install psutil pip3 install crcengine pip3 install pyinstaller - name: Build with Pyinstaller Linux if: matrix.os == 'ubuntu-latest' working-directory: tnc run: | pyinstaller -F daemon.py -n daemon pyinstaller -F main.py -n tnc # cd dist # ls -R - name: Compress Linux shell: bash run: | cd ./tnc/dist mkdir ../compressed zip -r ../compressed/${{ matrix.zip_name }}.zip * - name: Release Linux 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 - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v1 with: node-version: 14 #- name: Upload Linux # uses: actions/upload-release-asset@v1 # env: # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # with: # upload_url: ${{ needs.create_release.outputs.upload_url }} # asset_path: ./tnc/artifact/${{ matrix.zip_name }}.zip # asset_name: ${{ matrix.zip_name }}.zip # asset_content_type: application/zip