Merge pull request #17 from jakeshirey/feature/gh-release #5
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 Workflow | |
on: | |
push: | |
branches: main | |
jobs: | |
build-windows: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
architecture: 'x64' | |
- name: Install requirements | |
run: | | |
pip install -r requirements.txt | |
- name: Run PyInstaller | |
run: | | |
python -m PyInstaller mainGUI.spec | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: DeepLabCut-Display | |
path: dist/DeepLabCut-Display.exe | |
- name: create release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.event.head_commit.message }} | |
release_name: ${{ github.event.head_commit.message }} | |
body: | | |
Release v1.0.0 | |
draft: false | |
prerelease: false | |
- name: Upload Release Asset | |
id: upload-release-asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{steps.create_release.outputs.upload_url}} | |
asset_path: dist/DeepLabCut-Display.exe | |
asset_name: DeepLabCut-Display.exe | |
asset_content_type: application/zip |