-
Notifications
You must be signed in to change notification settings - Fork 0
82 lines (69 loc) · 2.25 KB
/
Copy pathrelease.yml
File metadata and controls
82 lines (69 loc) · 2.25 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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: Build and Release NullifyPDF
on:
push:
tags:
- 'v*'
workflow_dispatch:
permissions:
contents: write
actions: read
jobs:
build:
name: Build for ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-22.04, macos-latest]
steps:
- name: Checkout Code
uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.12'
cache: 'pip' # CACHE RIPRISTINATA!
- name: Install System Dependencies (Linux)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y rpm dpkg binutils libxcb-cursor0 libxkbcommon-x11-0 libegl1 desktop-file-utils
- name: Install Python Dependencies (includes spaCy models)
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run Smoke Tests
run: pytest tests/ -v
- name: Type Check (mypy)
run: mypy NullifyPDF.py --ignore-missing-imports --no-error-summary 2>&1 | head -50 || true
- name: Build
run: python build_local.py
- name: Upload Artifact
uses: actions/upload-artifact@v7
with:
name: build-${{ runner.os }}
path: |
dist/NullifyPDF_v*_Windows.exe
dist/NullifyPDF_v*_macOS.zip
dist/NullifyPDF_v*_Ubuntu.deb
dist/NullifyPDF_v*_Fedora.rpm
create_release:
name: Create GitHub Release
needs: build
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
steps:
- name: Download All Artifacts
uses: actions/download-artifact@v8
with:
path: all-builds
pattern: build-*
merge-multiple: true
- name: Release
uses: softprops/action-gh-release@v3
with:
files: |
all-builds/NullifyPDF_v*_Windows.exe
all-builds/NullifyPDF_v*_macOS.zip
all-builds/NullifyPDF_v*_Ubuntu.deb
all-builds/NullifyPDF_v*_Fedora.rpm
body: "Release Stabile NullifyPDF. Include App Bundle macOS (ZIP), EXE per Windows e pacchetti nativi Linux."
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}