Skip to content

Workflow file for this run

name: Build and Publish Binary
on:
push:
branches:
- master
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- uses: actions/setup-python@v5
with:
python-version: '3.9'
cache: 'pip' # caching pip dependencies
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt pyinstaller
- name: Build binary with PyInstaller
run: |
pyinstaller --onefile --clean src/genpeerid.py
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: genpeerid
path: dist/genpeerid
- name: Bump version and tag
id: bump_version
uses: anothrNick/github-tag-action@v1
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
WITH_V: false
- name: Create Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
with:
files: dist/genpeerid