forked from coolsnowwolf/lede
-
Notifications
You must be signed in to change notification settings - Fork 0
70 lines (60 loc) · 2.03 KB
/
openwrt-ci.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
67
68
69
70
#
# <https://github.com/KFERMercer/OpenWrt-CI>
#
# Copyright (C) 2019 P3TERX
#
# Copyright (C) 2020 KFERMercer
#
name: OpenWrt-CI
on:
release:
types: [published]
push:
branches:
- master
watch:
types: [started]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: Initialization environment
env:
DEBIAN_FRONTEND: noninteractive
run: |
docker rmi `docker images -q`
# sudo rm -rf /usr/share/dotnet /etc/mysql /etc/php /etc/apt/sources.list.d
sudo -E apt-get -y purge ghc* zulu* hhvm llvm* firefox google* dotnet* powershell openjdk* mysql* php* android*
sudo -E apt-get update
sudo -E apt-get -y install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs gcc-multilib g++-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler antlr3 gperf swig
sudo -E apt-get -y autoremove --purge
sudo -E apt-get clean
- name: Download dependencies
run: |
git clone https://github.com/vernesong/OpenClash package/luci-app-openclash --no-checkout --depth=1
cd package/luci-app-openclash
git sparse-checkout init --cone
git sparse-checkout set luci-app-openclash
git checkout
cd ../../
- name: Update & Install feeds
run: |
./scripts/feeds update -a
./scripts/feeds install -a
- name: Generate configuration file
run: make defconfig
- name: Download package
run: |
make download -j$(nproc)
find dl -size -1024c -exec rm -f {} \;
- name: Build firmware
run: |
echo -e "$(nproc) thread build."
make -j$(nproc) V=s
- name : Upload artifact
uses: actions/upload-artifact@master
with:
name: OpenWrt
path: ./bin/targets/