-
-
Notifications
You must be signed in to change notification settings - Fork 2
66 lines (56 loc) · 1.58 KB
/
build_scan_and_release.yml
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
name: Build, Scan, and Release
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: windows-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
pip install pyinstaller
- name: Build EXE
run: |
pyinstaller --onefile --noconsole --name="MiniBin-KT" --add-data "icons;icons" --icon=icons/minibin-kt-full.ico --hidden-import=plyer.platforms.win --hidden-import=plyer.platforms.win.notification app.py
env:
PYTHONIOENCODING: utf-8
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: built-exe
path: dist/MiniBin-KT.exe
- name: VirusTotal GitHub Action
uses: crazy-max/ghaction-virustotal@v4.0.0
with:
vt_api_key: ${{ secrets.VIRUSTOTAL_API_KEY }}
files: dist/MiniBin-KT.exe
release:
needs: build
runs-on: ubuntu-latest
steps:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: built-exe
- name: Create GitHub Release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v${{ github.run_number }}
release_name: Release v${{ github.run_number }}
draft: false
prerelease: false
files: dist/MiniBin-KT.exe