-
-
Notifications
You must be signed in to change notification settings - Fork 132
62 lines (50 loc) · 1.44 KB
/
Copy pathbuild.yml
File metadata and controls
62 lines (50 loc) · 1.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Build
on:
push:
branches: [ main ]
tags: [ 'v*' ]
pull_request:
branches: [ main ]
jobs:
build:
name: Build on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
permissions:
contents: write
strategy:
fail-fast: false
matrix:
# macos-13 is the last Intel runner
# macos-14 is Apple Silicon (M1)
os: [ubuntu-latest, windows-latest, macos-14]
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
- name: Set up Python
run: uv python install 3.12
- name: Install dependencies
run: uv sync
- name: Build with PyInstaller
run: uv run python build_app.py
- name: Zip Build Output (Unix)
if: runner.os != 'Windows'
run: |
cd dist
zip -r ../gmail-cleaner-${{ matrix.os }}.zip gmail-cleaner/
- name: Zip Build Output (Windows)
if: runner.os == 'Windows'
run: |
Compress-Archive -Path dist/gmail-cleaner -DestinationPath gmail-cleaner-${{ matrix.os }}.zip
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: gmail-cleaner-${{ matrix.os }}
path: gmail-cleaner-${{ matrix.os }}.zip
if-no-files-found: error
retention-days: 30
- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
files: gmail-cleaner-${{ matrix.os }}.zip