Update macos.yml #9
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: Auto Compile on Commit (macOS) | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: macos-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Build the application with PyInstaller | |
run: | | |
pyinstaller script.spec | |
- name: List contents of the output directory | |
run: | | |
ls -R dist # Recursively list all files in the 'dist' directory | |
- name: Prepare files for zipping | |
run: | | |
mkdir -p zip_temp | |
mv dist/Vector24 zip_temp/ # Adjust path based on actual build output | |
mv app.log zip_temp/ | |
mv config.json zip_temp/ | |
mv positions.json zip_temp/ | |
mv startup.mp3 zip_temp/ | |
mv version.json zip_temp/ | |
- name: Create ZIP archive | |
run: | | |
cd zip_temp | |
zip -r ../Vector24-ADDVNAME-amd64-macos.zip ./* | |
- name: Upload ZIP as an artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: final-zip-package | |
path: Vector24-ADDVNAME-amd64-macos.zip |