diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e9de7d6..69f225d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,7 +6,7 @@ on: name: Build Executable jobs: - build-release: + build-windows: name: Build Windows Executable runs-on: windows-latest steps: @@ -26,11 +26,64 @@ jobs: run: .\build.bat - name: Rename executable - run: mv "bin/MobyStk.exe" "bin/MobyStk ${{github.ref_name}}.exe" + run: mv "bin/MobyStk.exe" "bin/MobyStk-${{github.ref_name}}-Windows-x64.exe" - - name: Release + - name: Upload Artifact + uses: actions/upload-artifact@v4 + with: + name: windows-build + path: bin/MobyStk-${{github.ref_name}}-Windows-x64.exe + + build-linux: + name: Build Linux Executable + runs-on: ubuntu-latest + steps: + - name: Install Python + uses: actions/setup-python@v5 + with: + python-version: 3.13 + architecture: x64 + + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Build + uses: coactions/setup-xvfb@v1 + with: + run: | + chmod +x build.sh + ./build.sh + + - name: Rename executable + run: mv "bin/MobyStk" "bin/MobyStk-${{github.ref_name}}-Linux-x64" + + - name: Upload Artifact + uses: actions/upload-artifact@v4 + with: + name: linux-build + path: bin/MobyStk-${{github.ref_name}}-Linux-x64 + + create-release: + name: Create Release + runs-on: ubuntu-latest + needs: [build-windows, build-linux] + steps: + - name: Download Artifacts (Windows) + uses: actions/download-artifact@v4 + with: + name: windows-build + + - name: Download Artifacts (Linux) + uses: actions/download-artifact@v4 + with: + name: linux-build + + - name: Create Release uses: softprops/action-gh-release@v2 with: body: '' - files: bin/MobyStk ${{github.ref_name}}.exe - prerelease: ${{ endsWith(github.ref_name, '-beta') }} + files: | + ./MobyStk-${{github.ref_name}}-Windows-x64.exe + ./MobyStk-${{github.ref_name}}-Linux-x64 + fail_on_unmatched_files: true + prerelease: ${{endsWith(github.ref_name, '-beta')}} diff --git a/build.sh b/build.sh index 8ac855c..0449925 100644 --- a/build.sh +++ b/build.sh @@ -1,5 +1,7 @@ #!/bin/bash +PYTHON_CMD=$(command -v python3 || command -v python) + # Configura o ambiente virtual if [ ! -d "venv" ]; then $PYTHON_CMD -m venv venv diff --git a/server/src/module_check.py b/server/src/module_check.py index 47f489b..8537893 100644 --- a/server/src/module_check.py +++ b/server/src/module_check.py @@ -12,6 +12,7 @@ ("colorama", "0.4.6"), ("jsonschema", "4.23.0"), ("prompt_toolkit", "3.0.48"), + ("psutil", "6.1.1"), ("pyqrcode", "1.2.1"), ("pynput", "1.7.7"), ("requests", "2.32.3"),