-
Notifications
You must be signed in to change notification settings - Fork 0
70 lines (58 loc) · 1.8 KB
/
build-dev.yml
File metadata and controls
70 lines (58 loc) · 1.8 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
name: Build-DEV
on:
workflow_dispatch:
jobs:
variables:
name: Assign variables
outputs:
sem_ver: ${{ steps.var.outputs.sem_ver }}
runs-on: "ubuntu-latest"
steps:
- name: Split branch name
id: split
run: echo "fragment=${${{ github.ref_name }}%%/*}" >> $GITHUB_OUTPUT
- name: Setting global variables
uses: actions/github-script@v7
id: var
with:
script: |
core.setOutput('sem_ver', '${{ github.ref_name }}'.replaceAll('\/', '-'))
windows_build:
name: Build and Zip
needs: [variables]
runs-on: windows-latest
defaults:
run:
shell: powershell
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version-file: '.python-version'
architecture: "x86"
cache: 'pip' # caching pip dependencies
- name: Install python requirements
run: |
pip install -r requirements.txt
- name: Build runED
run: |
pyinstaller main.py --name runED --icon img\runED.ico --workpath build --contents-directory . --distpath .\dist --clean
- name: Add files to dist
run: |
$files = ( 'CHANGELOG.md', 'README.md', 'UNLICENSE' ); foreach ( $file in $files ) { Copy-Item -Path $file -Destination '.\dist\runED\' }
- name: Zip it
uses: thedoctor0/zip-release@main
with:
type: 'zip'
path: './dist/runED/'
filename: 'runED/runED-${{ needs.variables.outputs.sem_ver }}.zip'
- name: Upload build files
uses: actions/upload-artifact@v4
with:
name: built-files-windows
path: |
runED\runED-*.zip