From 2f0a0dc38eddd6485b3841c8a951250ed32ca739 Mon Sep 17 00:00:00 2001 From: Hyy2001X <1804430051@qq.com> Date: Fri, 26 Mar 2021 09:09:26 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=9E=B6=E6=9E=84,=E5=88=86?= =?UTF-8?q?=E7=A6=BB=E8=BD=AF=E4=BB=B6=E5=8C=85=E6=B7=BB=E5=8A=A0=E5=88=97?= =?UTF-8?q?=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../102-mt7621-fix-cpu-clk-add-clkdev.patch | 0 .../Depends/ImmortalWrt | 0 {Customize => CustomFiles}/Depends/banner | 0 {Customize => CustomFiles}/Depends/config-5.4 | 0 .../Depends/coremark_ImmortalWrt.sh | 0 .../Depends/coremark_lede.sh | 0 .../Depends/cpuinfo_x86 | 0 {Customize => CustomFiles}/mac80211.sh | 0 {Customize => CustomFiles}/mwan3.config | 0 {Customize => CustomFiles}/system_common | 0 {Customize => CustomFiles}/system_newifi-d2 | 0 {Customize => CustomFiles}/uhttpd.po | 0 {Customize => CustomFiles}/webadmin.po | 0 CustomPackages/d-team_newifi-d2 | 10 +++++++ CustomPackages/x86_64 | 10 +++++++ Scripts/AutoBuild_DiyScript.sh | 27 +++++------------ Scripts/AutoBuild_Function.sh | 29 +++++++++++++------ 17 files changed, 47 insertions(+), 29 deletions(-) rename {Customize => CustomFiles}/102-mt7621-fix-cpu-clk-add-clkdev.patch (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/ImmortalWrt (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/banner (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/config-5.4 (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/coremark_ImmortalWrt.sh (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/coremark_lede.sh (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/Depends/cpuinfo_x86 (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/mac80211.sh (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/mwan3.config (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/system_common (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/system_newifi-d2 (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/uhttpd.po (100%) mode change 100755 => 100644 rename {Customize => CustomFiles}/webadmin.po (100%) mode change 100755 => 100644 create mode 100644 CustomPackages/d-team_newifi-d2 create mode 100644 CustomPackages/x86_64 diff --git a/Customize/102-mt7621-fix-cpu-clk-add-clkdev.patch b/CustomFiles/102-mt7621-fix-cpu-clk-add-clkdev.patch old mode 100755 new mode 100644 similarity index 100% rename from Customize/102-mt7621-fix-cpu-clk-add-clkdev.patch rename to CustomFiles/102-mt7621-fix-cpu-clk-add-clkdev.patch diff --git a/Customize/Depends/ImmortalWrt b/CustomFiles/Depends/ImmortalWrt old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/ImmortalWrt rename to CustomFiles/Depends/ImmortalWrt diff --git a/Customize/Depends/banner b/CustomFiles/Depends/banner old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/banner rename to CustomFiles/Depends/banner diff --git a/Customize/Depends/config-5.4 b/CustomFiles/Depends/config-5.4 old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/config-5.4 rename to CustomFiles/Depends/config-5.4 diff --git a/Customize/Depends/coremark_ImmortalWrt.sh b/CustomFiles/Depends/coremark_ImmortalWrt.sh old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/coremark_ImmortalWrt.sh rename to CustomFiles/Depends/coremark_ImmortalWrt.sh diff --git a/Customize/Depends/coremark_lede.sh b/CustomFiles/Depends/coremark_lede.sh old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/coremark_lede.sh rename to CustomFiles/Depends/coremark_lede.sh diff --git a/Customize/Depends/cpuinfo_x86 b/CustomFiles/Depends/cpuinfo_x86 old mode 100755 new mode 100644 similarity index 100% rename from Customize/Depends/cpuinfo_x86 rename to CustomFiles/Depends/cpuinfo_x86 diff --git a/Customize/mac80211.sh b/CustomFiles/mac80211.sh old mode 100755 new mode 100644 similarity index 100% rename from Customize/mac80211.sh rename to CustomFiles/mac80211.sh diff --git a/Customize/mwan3.config b/CustomFiles/mwan3.config old mode 100755 new mode 100644 similarity index 100% rename from Customize/mwan3.config rename to CustomFiles/mwan3.config diff --git a/Customize/system_common b/CustomFiles/system_common old mode 100755 new mode 100644 similarity index 100% rename from Customize/system_common rename to CustomFiles/system_common diff --git a/Customize/system_newifi-d2 b/CustomFiles/system_newifi-d2 old mode 100755 new mode 100644 similarity index 100% rename from Customize/system_newifi-d2 rename to CustomFiles/system_newifi-d2 diff --git a/Customize/uhttpd.po b/CustomFiles/uhttpd.po old mode 100755 new mode 100644 similarity index 100% rename from Customize/uhttpd.po rename to CustomFiles/uhttpd.po diff --git a/Customize/webadmin.po b/CustomFiles/webadmin.po old mode 100755 new mode 100644 similarity index 100% rename from Customize/webadmin.po rename to CustomFiles/webadmin.po diff --git a/CustomPackages/d-team_newifi-d2 b/CustomPackages/d-team_newifi-d2 new file mode 100644 index 0000000..958ac14 --- /dev/null +++ b/CustomPackages/d-team_newifi-d2 @@ -0,0 +1,10 @@ +git other OpenClash https://github.com/vernesong master +git other luci-app-argon-config https://github.com/jerrykuku +git other luci-app-adguardhome https://github.com/Hyy2001X +svn other luci-app-smartdns https://github.com/immortalwrt/immortalwrt/trunk/package/ntlf9t +git other luci-app-serverchan https://github.com/tty228 +svn other luci-app-socat https://github.com/Lienol/openwrt-package/trunk +svn other luci-app-usb3disable https://github.com/immortalwrt/luci/trunk/applications +svn other luci-app-eqos https://github.com/immortalwrt/immortalwrt/trunk/package/ntlf9t +git other luci-app-bearDropper https://github.com/NateLol +git other luci-app-onliner https://github.com/rufengsuixing diff --git a/CustomPackages/x86_64 b/CustomPackages/x86_64 new file mode 100644 index 0000000..1e50f4c --- /dev/null +++ b/CustomPackages/x86_64 @@ -0,0 +1,10 @@ +git other OpenClash https://github.com/vernesong master +git other openwrt-passwall https://github.com/xiaorouji main +git other luci-app-argon-config https://github.com/jerrykuku +git other luci-app-adguardhome https://github.com/Hyy2001X +git other luci-app-shutdown https://github.com/Hyy2001X +svn other luci-app-smartdns https://github.com/immortalwrt/immortalwrt/trunk/package/ntlf9t +git other luci-app-serverchan https://github.com/tty228 +svn other luci-app-socat https://github.com/Lienol/openwrt-package/trunk +git other luci-app-bearDropper https://github.com/NateLol +git other luci-app-onliner https://github.com/rufengsuixing diff --git a/Scripts/AutoBuild_DiyScript.sh b/Scripts/AutoBuild_DiyScript.sh index 6eb38bf..0f21eed 100755 --- a/Scripts/AutoBuild_DiyScript.sh +++ b/Scripts/AutoBuild_DiyScript.sh @@ -17,37 +17,24 @@ Diy-Part1() { Update_Makefile xray-core package/lean/helloworld/xray-core Update_Makefile exfat package/kernel/exfat - - ExtraPackages git other OpenClash https://github.com/vernesong master - ExtraPackages git other openwrt-passwall https://github.com/xiaorouji main - ExtraPackages git other luci-app-argon-config https://github.com/jerrykuku - ExtraPackages git other luci-app-adguardhome https://github.com/Hyy2001X - ExtraPackages git other luci-app-shutdown https://github.com/Hyy2001X - ExtraPackages svn other luci-app-smartdns https://github.com/immortalwrt/immortalwrt/trunk/package/ntlf9t - ExtraPackages git other luci-app-serverchan https://github.com/tty228 - ExtraPackages svn other luci-app-socat https://github.com/Lienol/openwrt-package/trunk - ExtraPackages svn other luci-app-usb3disable https://github.com/immortalwrt/luci/trunk/applications - ExtraPackages svn other luci-app-eqos https://github.com/immortalwrt/immortalwrt/trunk/package/ntlf9t - ExtraPackages git other luci-app-bearDropper https://github.com/NateLol - ExtraPackages git other luci-app-onliner https://github.com/rufengsuixing } Diy-Part2() { Diy_Part2_Base ExtraPackages svn other/../../feeds/packages/admin netdata https://github.com/openwrt/packages/trunk/admin - Replace_File Customize/uhttpd.po feeds/luci/applications/luci-app-uhttpd/po/zh-cn - Replace_File Customize/webadmin.po package/lean/luci-app-webadmin/po/zh-cn - Replace_File Customize/mwan3.config package/feeds/packages/mwan3/files/etc/config mwan3 + Replace_File CustomFiles/uhttpd.po feeds/luci/applications/luci-app-uhttpd/po/zh-cn + Replace_File CustomFiles/webadmin.po package/lean/luci-app-webadmin/po/zh-cn + Replace_File CustomFiles/mwan3.config package/feeds/packages/mwan3/files/etc/config mwan3 case ${TARGET_PROFILE} in d-team_newifi-d2) - Replace_File Customize/mac80211.sh package/kernel/mac80211/files/lib/wifi - Replace_File Customize/system_newifi-d2 package/base-files/files/etc/config system - Replace_File Customize/102-mt7621-fix-cpu-clk-add-clkdev.patch target/linux/ramips/patches-5.4 + Replace_File CustomFiles/mac80211.sh package/kernel/mac80211/files/lib/wifi + Replace_File CustomFiles/system_newifi-d2 package/base-files/files/etc/config system + Replace_File CustomFiles/102-mt7621-fix-cpu-clk-add-clkdev.patch target/linux/ramips/patches-5.4 ;; *) - Replace_File Customize/system_common package/base-files/files/etc/config system + Replace_File CustomFiles/system_common package/base-files/files/etc/config system ;; esac } diff --git a/Scripts/AutoBuild_Function.sh b/Scripts/AutoBuild_Function.sh index 67f9564..0bfa2da 100755 --- a/Scripts/AutoBuild_Function.sh +++ b/Scripts/AutoBuild_Function.sh @@ -52,6 +52,7 @@ GET_TARGET_INFO() { Diy_Part1_Base() { Diy_Core + if [[ "${INCLUDE_AutoBuild_Tools}" == "true" ]];then Replace_File Scripts/AutoBuild_Tools.sh package/base-files/files/bin fi @@ -59,8 +60,7 @@ Diy_Part1_Base() { Diy_Part2_Base() { GET_TARGET_INFO - - Replace_File Customize/Depends/banner package/base-files/files/etc + Auto_ExtraPackages if [[ "${INCLUDE_AutoUpdate}" == "true" ]];then ExtraPackages git lean luci-app-autoupdate https://github.com/Hyy2001X main Replace_File Scripts/AutoUpdate.sh package/base-files/files/bin @@ -69,27 +69,28 @@ Diy_Part2_Base() { else sed -i "s?Openwrt?Openwrt ${Openwrt_Version}?g" package/base-files/files/etc/banner fi + Replace_File CustomFiles/Depends/banner package/base-files/files/etc + Replace_File CustomFiles/Depends/cpuinfo_x86 package/lean/autocore/files/x86/sbin cpuinfo case ${Source_Owner} in coolsnowwolf) - Replace_File Customize/Depends/cpuinfo_x86 package/lean/autocore/files/x86/sbin cpuinfo ExtraPackages git lean luci-theme-argon https://github.com/jerrykuku 18.06 ExtraPackages git lean helloworld https://github.com/fw876 master Update_Makefile xray-core package/lean/helloworld/xray-core sed -i 's/143/143,8080/' package/lean/helloworld/luci-app-ssr-plus/root/etc/init.d/shadowsocksr - Replace_File Customize/Depends/coremark_lede.sh package/lean/coremark coremark.sh + Replace_File CustomFiles/Depends/coremark_lede.sh package/lean/coremark coremark.sh ExtraPackages svn other/../../feeds/packages/admin netdata https://github.com/openwrt/packages/trunk/admin - + sed -i "s?iptables?#iptables?g" ${Version_File} > /dev/null 2>&1 sed -i "s?${Old_Version}?${Old_Version} Compiled by ${Author} [${Display_Date}]?g" $Version_File if [[ "${INCLUDE_DRM_I915}" == "true" ]];then - Replace_File Customize/Depends/config-5.4 target/linux/x86 + Replace_File CustomFiles/Depends/config-5.4 target/linux/x86 fi ;; immortalwrt) sed -i 's/143/143,8080/' package/lean/luci-app-ssr-plus/root/etc/init.d/shadowsocksr - Replace_File Customize/Depends/coremark_ImmortalWrt.sh package/base-files/files/etc coremark.sh - Replace_File Customize/Depends/ImmortalWrt package/base-files/files/etc openwrt_release + Replace_File CustomFiles/Depends/coremark_ImmortalWrt.sh package/base-files/files/etc coremark.sh + Replace_File CustomFiles/Depends/ImmortalWrt package/base-files/files/etc openwrt_release sed -i "s?Template?Compiled by ${Author} [${Display_Date}]?g" $Version_File ;; *) @@ -186,6 +187,16 @@ PKG_Finder() { fi } +Auto_ExtraPackages() { + [[ ! -f "${GITHUB_WORKSPACE}/CustomPackages/${TARGET_PROFILE}" ]] && return + echo "CustomFile: ${TARGET_PROFILE} is detected !" + cat ${GITHUB_WORKSPACE}/CustomPackages/${TARGET_PROFILE} | while read X + do + ExtraPackages ${X} + done + echo "Done !" +} + ExtraPackages() { PKG_PROTO=${1} PKG_DIR=${2} @@ -233,7 +244,7 @@ Replace_File() { echo "[$(date "+%H:%M:%S")] Moving [${_TYPE2}] ${FILE_NAME} to ${2}/${FILE_RENAME} ..." mv -f ${GITHUB_WORKSPACE}/${FILE_NAME} ${PATCH_DIR}/${_RENAME} else - echo "[$(date "+%H:%M:%S")] Customize ${_TYPE2} [${FILE_NAME}] is not detected,skip move ..." + echo "[$(date "+%H:%M:%S")] CustomFiles ${_TYPE2} [${FILE_NAME}] is not detected,skip move ..." fi fi unset FILE_NAME PATCH_DIR FILE_RENAME