From 0bdcd04902b860b50d872eaf009d50c631fe9ccd Mon Sep 17 00:00:00 2001 From: zzl3001 <130136505+zzl3001@users.noreply.github.com> Date: Fri, 7 Apr 2023 16:04:17 +0800 Subject: [PATCH 1/3] Update build-padavan.yml --- .github/workflows/build-padavan.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-padavan.yml b/.github/workflows/build-padavan.yml index 3af88b853c..490f1504ae 100644 --- a/.github/workflows/build-padavan.yml +++ b/.github/workflows/build-padavan.yml @@ -44,7 +44,7 @@ jobs: mkdir -p /opt/images/ - name: Build Firmware env: - TNAME: K2P + TNAME: MI-R3G KERNEL: 3.4 run: | cd /opt/rt-n56u/trunk From baddb1ad8d128df9f45a5be723438db4d7e9e60e Mon Sep 17 00:00:00 2001 From: zzl3001 <130136505+zzl3001@users.noreply.github.com> Date: Fri, 7 Apr 2023 20:30:05 +0800 Subject: [PATCH 2/3] Create blank.yml --- .../blank.yml" | 128 ++++++++++++++++++ 1 file changed, 128 insertions(+) create mode 100644 ".\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" diff --git "a/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" "b/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" new file mode 100644 index 0000000000..872dda08eb --- /dev/null +++ "b/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" @@ -0,0 +1,128 @@ +name: Build Padavan + +on: + release: + types: [published] + push: + tags: + - 'v*' + # branches: + # - master +# schedule: +# - cron: 0 8 * * 5 + watch: + types: [started] + +jobs: + build: + runs-on: ubuntu-18.04 + if: github.event.repository.owner.id == github.event.sender.id + + steps: + - name: Checkout + uses: actions/checkout@master + - name: Initialization environment + env: + DEBIAN_FRONTEND: noninteractive + run: | + sudo apt-get update + sudo apt-get -y install unzip libtool-bin curl cmake gperf gawk flex bison nano xxd fakeroot \ + cpio git python-docutils gettext automake autopoint texinfo build-essential help2man \ + pkg-config zlib1g-dev libgmp3-dev libmpc-dev libmpfr-dev libncurses5-dev libltdl-dev wget + - name: Clone source code + env: + KERNEL: 3.4 + run: | + if [ $KERNEL = "4.4" ] ; then + git clone --depth=1 https://github.com/MeIsReallyBa/padavan-4.4.git /opt/rt-n56u + else + git clone --depth=1 https://github.com/chongshengB/rt-n56u.git /opt/rt-n56u + fi + cd /opt/rt-n56u/toolchain-mipsel + sh dl_toolchain.sh + mkdir -p /opt/images/ + - name: Build Firmware + env: + TNAME: MI-R3G + KERNEL: 3.4 + run: | + cd /opt/rt-n56u/trunk + if [ ! -f configs/templates/$TNAME.config ] ; then + echo "configs/templates/$TNAME.config not found " + exit 1 + fi + cp -f configs/templates/$TNAME.config .config + sed -i 's/CONFIG_FIRMWARE_INCLUDE_OPENSSL_EXE=n/CONFIG_FIRMWARE_INCLUDE_OPENSSL_EXE=y/g' .config + ################################################################################################ + #因不同型号配置功能不一样,所以先把配置项删除,如果你自己要添加其他的,也要写上删除这一条,切记!!! + ################################################################################################ + sed -i '/CONFIG_FIRMWARE_INCLUDE_MENTOHUST/d' .config #删除配置项MENTOHUST + sed -i '/CONFIG_FIRMWARE_INCLUDE_SCUTCLIENT/d' .config #删除配置项SCUTCLIENT + sed -i '/CONFIG_FIRMWARE_INCLUDE_SHADOWSOCKS/d' .config #删除配置项SS plus+ + sed -i '/CONFIG_FIRMWARE_INCLUDE_SSSERVER/d' .config #删除配置项SS server + sed -i '/CONFIG_FIRMWARE_INCLUDE_DNSFORWARDER/d' .config #删除配置项DNSFORWARDER + sed -i '/CONFIG_FIRMWARE_INCLUDE_ADBYBY/d' .config #删除配置项adbyby plus+ + sed -i '/CONFIG_FIRMWARE_INCLUDE_FRPC/d' .config #删除配置项adbyby plus+ + sed -i '/CONFIG_FIRMWARE_INCLUDE_FRPS/d' .config #删除配置项adbyby plus+ + sed -i '/CONFIG_FIRMWARE_INCLUDE_TUNSAFE/d' .config #删除配置项adbyby plus+ + sed -i '/CONFIG_FIRMWARE_INCLUDE_ALIDDNS/d' .config #删除配置项阿里DDNS + sed -i '/CONFIG_FIRMWARE_INCLUDE_SMARTDNS/d' .config + sed -i '/CONFIG_FIRMWARE_INCLUDE_SRELAY/d' .config + sed -i 's/CONFIG_FIRMWARE_INCLUDE_OPENSSL_EXE=n/CONFIG_FIRMWARE_INCLUDE_OPENSSL_EXE=y/g' .config + ###################################################################### + #以下选项是定义你需要的功能(y=集成,n=忽略),重新写入到.config文件 + ###################################################################### + if [ $KERNEL = "4.4" ] ; then + echo "CONFIG_FIRMWARE_INCLUDE_MENTOHUST=n" >> .config #MENTOHUST + echo "CONFIG_FIRMWARE_INCLUDE_SCUTCLIENT=n" >> .config #SCUTCLIENT + echo "CONFIG_FIRMWARE_INCLUDE_SHADOWSOCKS=y" >> .config #SS plus+ + echo "CONFIG_FIRMWARE_INCLUDE_SSOBFS=n" >> .config # simple-obfs混淆插件 + echo "CONFIG_FIRMWARE_INCLUDE_ADBYBY=y" >> .config #adbyby plus+ + echo "CONFIG_FIRMWARE_INCLUDE_DNSFORWARDER=n" >> .config #DNSFORWARDER + echo "CONFIG_FIRMWARE_INCLUDE_SRELAY=n" >> .config #可以不集成 + echo "CONFIG_FIRMWARE_INCLUDE_XRAY=y" >> .config #集成xray执行文件 ~4.5M + echo "CONFIG_FIRMWARE_INCLUDE_V2RAY=n" >> .config #集成v2ray执行文件 + echo "CONFIG_FIRMWARE_INCLUDE_DDNSTO=y" >> .config #ddnsto ~0.5M + echo "CONFIG_FIRMWARE_INCLUDE_ALDRIVER=n" >> .config #阿里云盘 ~3m + echo "CONFIG_FIRMWARE_INCLUDE_ZEROTIER=n" >> .config #zerotier ~1.3M + echo "CONFIG_FIRMWARE_INCLUDE_ALIDDNS=y" >> .config #aliddns + else + echo "CONFIG_FIRMWARE_INCLUDE_MENTOHUST=n" >> .config #MENTOHUST + echo "CONFIG_FIRMWARE_INCLUDE_SCUTCLIENT=n" >> .config #SCUTCLIENT + echo "CONFIG_FIRMWARE_INCLUDE_SHADOWSOCKS=y" >> .config #SS plus+ + echo "CONFIG_FIRMWARE_INCLUDE_SSOBFS=n" >> .config # simple-obfs混淆插件 + echo "CONFIG_FIRMWARE_INCLUDE_SSSERVER=n" >> .config #SS server + echo "CONFIG_FIRMWARE_INCLUDE_DNSFORWARDER=n" >> .config #DNSFORWARDER + echo "CONFIG_FIRMWARE_INCLUDE_ADBYBY=y" >> .config #adbyby plus+ + echo "CONFIG_FIRMWARE_INCLUDE_FRPC=n" >> .config #内网穿透FRPC + echo "CONFIG_FIRMWARE_INCLUDE_FRPS=n" >> .config #内网穿透FRPS + echo "CONFIG_FIRMWARE_INCLUDE_TUNSAFE=n" >> .config #TUNSAFE + echo "CONFIG_FIRMWARE_INCLUDE_ALIDDNS=y" >> .config #阿里DDNS + echo "CONFIG_FIRMWARE_INCLUDE_SMARTDNS=y" >> .config #smartdns + echo "CONFIG_FIRMWARE_INCLUDE_SMARTDNSBIN=y" >> .config #smartdns二进制文件 + echo "CONFIG_FIRMWARE_INCLUDE_V2RAY=n" >> .config #集成v2ray执行文件(3.8M左右),如果不集成,会从网上下载下来执行,不影响正常使用 + echo "CONFIG_FIRMWARE_INCLUDE_TROJAN=n" >> .config #集成trojan执行文件(1.1M左右),如果不集成,会从网上下载下来执行,不影响正常使用 + echo "CONFIG_FIRMWARE_INCLUDE_KOOLPROXY=y" >> .config #KP广告过滤 + echo "CONFIG_FIRMWARE_INCLUDE_CADDY=y" >> .config #在线文件管理服务 + echo "CONFIG_FIRMWARE_INCLUDE_CADDYBIN=n" >> .config #集成caddu执行文件,此文件有13M,请注意固件大小。如果不集成,会从网上下载下来执行,不影响正常使用 + echo "CONFIG_FIRMWARE_INCLUDE_ADGUARDHOME=y" >> .config + echo "CONFIG_FIRMWARE_INCLUDE_SRELAY=n" >> .config #可以不集成 + echo "CONFIG_FIRMWARE_INCLUDE_WYY=y" >> .config #网易云解锁 + echo "CONFIG_FIRMWARE_INCLUDE_WYYBIN=n" >> .config #网易云解锁GO版本执行文件(4M多)注意固件超大小,不集成会自动下载 + echo "CONFIG_FIRMWARE_INCLUDE_ZEROTIER=n" >> .config #zerotier ~1.3M + fi + ######################################################################################### + #自定义添加其它功能请参考源码configs/templates/目录下的config文件。按照上面的格式添加即可 + #格式如下: + #sed -i '/自定义项/d' .config + #echo "自定义项=y" >> .config + ######################################################################################### + sudo ./clear_tree + sudo ./build_firmware_modify $TNAME 0 + sudo mv -f images/*.trx /opt/images/ + - name : Upload packages + uses: actions/upload-artifact@master + if: always() + with: + name: Padavan-packages + path: /opt/images From b78cea8ec0de9471d997437971f667fe98d33c4f Mon Sep 17 00:00:00 2001 From: zzl3001 <130136505+zzl3001@users.noreply.github.com> Date: Fri, 7 Apr 2023 20:34:18 +0800 Subject: [PATCH 3/3] Update blank.yml --- .../blank.yml" | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git "a/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" "b/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" index 872dda08eb..14213e818f 100644 --- "a/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" +++ "b/.\344\275\206 /\345\267\245\344\275\234\346\265\201\347\250\213 /blank.yml" @@ -36,7 +36,7 @@ jobs: if [ $KERNEL = "4.4" ] ; then git clone --depth=1 https://github.com/MeIsReallyBa/padavan-4.4.git /opt/rt-n56u else - git clone --depth=1 https://github.com/chongshengB/rt-n56u.git /opt/rt-n56u + git clone --depth=1 https://github.com/vogo007/rt-n56u.git /opt/rt-n56u fi cd /opt/rt-n56u/toolchain-mipsel sh dl_toolchain.sh