Update build_executables.yml #39
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 Executables | |
on: | |
push: | |
branches: | |
- main | |
- jon/fastapi | |
workflow_dispatch: | |
jobs: | |
build-ubuntu: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.11" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2 | |
with: | |
poetry-version: "1.8.3" | |
- name: Setup a local virtual environment | |
run: | | |
poetry config virtualenvs.create true --local | |
poetry config virtualenvs.in-project true --local | |
- uses: actions/cache@v3 | |
name: Define a cache for the virtual environment based on the dependencies lock file | |
with: | |
path: ./.venv | |
key: venv-${{ hashFiles('poetry.lock') }} | |
- name: Install the project dependencies | |
run: | | |
poetry lock | |
poetry install | |
- name: Install Application dependencies | |
run: npm install | |
- name: Build Executable | |
run: npm run tauri-build | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-ubuntu | |
path: path/to/ubuntu/artifact | |
build-macos-latest: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.11" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2 | |
with: | |
poetry-version: "1.8.3" | |
- name: Setup a local virtual environment | |
run: | | |
poetry config virtualenvs.create true --local | |
poetry config virtualenvs.in-project true --local | |
- uses: actions/cache@v3 | |
name: Define a cache for the virtual environment based on the dependencies lock file | |
with: | |
path: ./.venv | |
key: venv-${{ hashFiles('poetry.lock') }} | |
- name: Install the project dependencies | |
run: | | |
poetry lock | |
poetry install | |
- name: Install Application dependencies | |
run: npm install | |
- name: Build Executable | |
run: npm run tauri-build | |
- name: Upload macOS App | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-app | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/macos/SkellyCam.app | |
- name: Upload DMG | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-dmg | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/dmg/SkellyCam_0.1.0_aarch64.dmg | |
build-macos-12: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.11" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2 | |
with: | |
poetry-version: "1.8.3" | |
- name: Setup a local virtual environment | |
run: | | |
poetry config virtualenvs.create true --local | |
poetry config virtualenvs.in-project true --local | |
- uses: actions/cache@v3 | |
name: Define a cache for the virtual environment based on the dependencies lock file | |
with: | |
path: ./.venv | |
key: venv-${{ hashFiles('poetry.lock') }} | |
- name: Install the project dependencies | |
run: | | |
poetry lock | |
poetry install | |
- name: Install Application dependencies | |
run: npm install | |
- name: Build Executable | |
run: npm run tauri-build | |
- name: Upload macOS App | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-app | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/macos/SkellyCam.app | |
- name: Upload DMG | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-dmg | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/dmg/SkellyCam_0.1.0_aarch64.dmg | |
build-macos-11: | |
runs-on: macos-11 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.11" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2 | |
with: | |
poetry-version: "1.8.3" | |
- name: Setup a local virtual environment | |
run: | | |
poetry config virtualenvs.create true --local | |
poetry config virtualenvs.in-project true --local | |
- uses: actions/cache@v3 | |
name: Define a cache for the virtual environment based on the dependencies lock file | |
with: | |
path: ./.venv | |
key: venv-${{ hashFiles('poetry.lock') }} | |
- name: Install the project dependencies | |
run: | | |
poetry lock | |
poetry install | |
- name: Install Application dependencies | |
run: npm install | |
- name: Build Executable | |
run: npm run tauri-build | |
- name: Upload macOS App | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-app | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/macos/SkellyCam.app | |
- name: Upload DMG | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-dmg | |
path: /Users/runner/work/skellycam/skellycam/src-tauri/target/release/bundle/dmg/SkellyCam_0.1.0_aarch64.dmg | |
build-windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.11" | |
- name: Run image | |
uses: abatilo/actions-poetry@v2 | |
with: | |
poetry-version: "1.8.3" | |
- name: Setup a local virtual environment | |
run: | | |
poetry config virtualenvs.create true --local | |
poetry config virtualenvs.in-project true --local | |
- uses: actions/cache@v3 | |
name: Define a cache for the virtual environment based on the dependencies lock file | |
with: | |
path: ./.venv | |
key: venv-${{ hashFiles('poetry.lock') }} | |
- name: Install the project dependencies | |
run: | | |
poetry lock | |
poetry install | |
- name: Install Application dependencies | |
run: npm install | |
- name: Build Executable | |
run: npm run tauri-build | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: SkellyCam-windows | |
path: path/to/windows/artifact |