-
Notifications
You must be signed in to change notification settings - Fork 18
54 lines (47 loc) · 1.42 KB
/
build-firmware.yaml
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
name: Build the Neighbor Link Firmware
on:
push:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-22.04
permissions:
contents: write
strategy:
fail-fast: false
matrix:
profile:
- "tplink_archer-c7-v5"
- "tplink_archer-c7-v2"
- "tplink_archer-a7-v5"
- "glinet_gl-mt300a"
- "tplink_archer-ax23-v1"
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set up Build Environment
run: |
sudo apt-get update -y
sudo apt-get install -y \
curl build-essential libncurses-dev zlib1g-dev \
gawk git gettext libssl-dev xsltproc rsync unzip \
python3 python3-distutils jq
- name: Build the Firmware
run: |
cd src
bash build.bash ${GITHUB_SHA::6} ${{ matrix.profile }}
echo "release_version=${GITHUB_SHA::6}" >> build/RELEASE_VERSION
- name: Upload Build Artifacts as a Single Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.profile }}_${{ github.sha }}
path: src/build/*
- name: Attach Artifacts to Release
uses: svenstaro/upload-release-action@v2
if: github.event_name == 'release'
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: src/build/*
tag: ${{ github.ref }}
file_glob: true