-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (45 loc) · 1.22 KB
/
genZip.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
name: 编译Windows文件
on:
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
with:
ref: 'main'
- name: 安装Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: 安装依赖
run: |
python -m pip install --upgrade pip
pip install virtualenv
python -m virtualenv ./python
- name: 开始编译
run: |
python\Scripts\activate
pip install -r requirements.txt
pip install pyinstaller
pip install distribution
pip install packaging
pip install tokenizers
pyinstaller autocut.spec -y
- name: 打包zip文件
uses: vimtor/action-zip@v1
with:
files: ./dist
dest: ./dist/autocut_windows.zip
- name: Upload to release
uses: JasonEtco/upload-to-release@master
with:
args: autocut_windows.zip application/octet-stream
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: 删除过多的workflows
uses: Mattraks/delete-workflow-runs@main
with:
token: ${{ secrets.AUTH_PAT }}
repository: ${{ github.repository }}
retain_days: 1