From 88c6f449d8bac9b8b897dbce946d7e4a319e1c9c Mon Sep 17 00:00:00 2001 From: Official-Husko Date: Sun, 30 Jun 2024 16:51:06 +0200 Subject: [PATCH] add github build actions --- .github/workflows/build_windows.yml | 44 +++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 .github/workflows/build_windows.yml diff --git a/.github/workflows/build_windows.yml b/.github/workflows/build_windows.yml new file mode 100644 index 0000000..85fccfa --- /dev/null +++ b/.github/workflows/build_windows.yml @@ -0,0 +1,44 @@ +name: Build Windows Executable + +on: + push: + branches: + - development + - oop-rewrite + +jobs: + build: + runs-on: windows-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: 3.12.4 # Specify the Python version you need + + - name: Create virtual environment and build + shell: bash + run: | + python -m venv .env + source .env/Scripts/activate + python -m pip install --upgrade pip + pip install pyinstaller + pip install -r requirements.txt # Replace with your requirements file if exists + + pyinstaller --paths .env/Lib/site-packages \ + --hidden-import plyer.platforms.win.filechooser \ + --add-data=".env/Lib/site-packages/grapheme/data/*;grapheme/data/" \ + --onefile \ + --icon "icon.ico" \ + --console \ + --name "Mul-Tor" \ + main.py + + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: mul-tor-windows + path: dist/Mul-Tor.exe # Adjust the path to your executable relative to the root of the repository