Update build-windows.yml #2
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-windows | |
permissions: | |
contents: write | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
check-latest: true | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install --upgrade -r requirements.txt | |
- name: Install PyInstaller | |
run: pip install --upgrade pyinstaller | |
- name: Build Executable with PyInstaller | |
run: | | |
pyinstaller --onefile --windowed Tornado.py | |
- name: Rename Executable | |
run: | | |
ren dist\\Tornado.exe Tornado.exe | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: | | |
dist/Tornado.exe | |
tag_name: 'latest' | |
make_latest: true | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |