-
Notifications
You must be signed in to change notification settings - Fork 9
59 lines (47 loc) · 1.39 KB
/
build.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
name: Build sb binary
on:
workflow_dispatch:
push:
paths:
- 'sb.py'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: self-hosted
steps:
- name: Install Git LFS
run: |
sudo apt-get update
sudo apt-get install -y git-lfs
git lfs install
- name: Check-out repository
uses: actions/checkout@v4
with:
lfs: true
- name: Setup venv
run: mkdir build
- name: Setup venv
run: cd build && python3.10 -m venv venv
- name: Install Dependencies
run: ./build/venv/bin/pip install -r requirements.txt
- name: List Pip modules
run: ./build/venv/bin/pip list
- name: Compile binary
run: cd build && ./venv/bin/python -m nuitka ../sb.py --onefile -o sb
- name: Copy binary and purge build directory
run: cp ./build/sb sb && rm -rf ./build
- name: chmod sb
run: chmod +x sb
- name: Commit changes
uses: EndBug/add-and-commit@v9
with:
author_name: Continuous Integration
author_email: username@users.noreply.github.com
message: 'Continuous Integration Updated Binary'
add: 'sb'
- uses: sarisia/actions-status-discord@v1
if: always()
with:
webhook: ${{ secrets.DISCORD_WEBHOOK }}