forked from yaya131/Openwrt_Beta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
diy-part2.sh
executable file
·162 lines (118 loc) · 7.73 KB
/
diy-part2.sh
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
#!/bin/bash
#
# Copyright (c) 2019-2020 P3TERX <https://p3terx.com>
#
# This is free software, licensed under the MIT License.
# See /LICENSE for more information.
#
# https://github.com/P3TERX/Actions-OpenWrt
# File name: diy-part2.sh
# Description: OpenWrt DIY script part 2 (After Update feeds)
#
# Modify default IP
sed -i 's/10.10.10.1/192.168.10.1/g' package/base-files/files/bin/config_generate
sed -i 's/192.168.1.1/192.168.10.1/g' package/base-files/files/bin/config_generate
# 修改连接数数
# sed -i 's/net.netfilter.nf_conntrack_max=.*/net.netfilter.nf_conntrack_max=65535/g' package/kernel/linux/files/sysctl-nf-conntrack.conf
# 修正连接数(by ベ七秒鱼ベ)
# sed -i '/customized in this file/a net.netfilter.nf_conntrack_max=65535' package/base-files/files/etc/sysctl.conf
# 设置密码为空(安装固件时无需密码登陆,然后自己修改想要的密码)
sed -i 's/$1$WplwC1t5$HBAtVXABp7XbvVjG4193B.:18753:0:99999:7/:0:0:99999:7/g' package/base-files/files/etc/shadow
sed -i 's@.*CYXluq4wUazHjmCDBCqXF*@#&@g' package/lean/default-settings/files/zzz-default-settings
# 移除不用软件包
# rm -rf package/lean/luci-app-ttyd
# rm -rf feeds/packages/utils/ttyd
# rm -rf package/lean/luci-theme-argon
# rm -rf feeds/packages/luci-app-argon-config
# rm -rf package/kernel/mac80211/files/lib/wifi
# rm -rf package/lean/reclone*
# rm -rf package/lean/luci-app-zerotier
# rm -rf package/lean/pdnsd-alt
# rm -rf package/lean/luci-app-easymesh
# 添加额外非必须软件包
# git clone https://github.com/garypang13/luci-app-bypass package/luci-app-bypass
# git clone https://github.com/vernesong/OpenClash.git package/OpenClash
# svn co https://github.com/jarod360/packages/trunk/ttyd package/ttyd
# git clone https://github.com/jarod360/luci-app-ttyd package/luci-app-ttyd
# svn co https://github.com/jarod360/openwrt/trunk/package/kernel/mac80211/files/lib/wifi package/kernel/mac80211/files/lib/wifi
# git clone https://github.com/esirplayground/luci-app-poweroff package/luci-app-poweroff
# git clone -b luci https://github.com/pexcn/openwrt-chinadns-ng.git package/luci-app-chinadns-ng
# svn co https://github.com/Boos4721/openwrt/trunk/package/lean/luci-app-cpufreq package/luci-app-cpufreq
# ServerChan
rm -rf package/luci-app-serverchan
rm -rf package/lean/luci-app-serverchan
rm -rf feeds/luci/applications/luci-app-serverchan
git clone https://github.com/tty228/luci-app-serverchan.git package/luci-app-serverchan
# Add theme(s)
# git clone -b 18.06 https://github.com/jerrykuku/luci-theme-argon package/luci-theme-argon
# git clone https://github.com/jerrykuku/luci-app-argon-config package/luci-app-argon-config
# git clone https://github.com/thinktip/luci-theme-neobird package/luci-theme-neobird
# sed -i 's/shadowsocksr/passwall/g' package/luci-theme-neobird/luasrc/view/themes/neobird/header.htm
# git clone https://github.com/gngpp/luci-theme-design.git package/luci-theme-design
# Smartdns
rm -rf package/luci-app-smartdns
rm -rf package/lean/luci-app-smartdns
rm -rf feeds/luci/applications/luci-app-smartdns
rm -rf package/smartdns
rm -rf package/lean/smartdns
rm -rf feeds/luci/applications/smartdns
git clone https://github.com/pymumu/openwrt-smartdns package/smartdns
git clone -b lede https://github.com/pymumu/luci-app-smartdns.git package/luci-app-smartdns
# Kick-ass
# git clone https://github.com/zaiyuyishiyoudu/luci-app-kickass package/luci-app-kickass
# Merge Lean's EasyMesh
# svn co https://github.com/coolsnowwolf/lede/trunk/package/lean/luci-app-easymesh package/luci-app-easymesh
# CPU Freq
# rm -rf package/luci-app-cpufreq
# rm -rf package/lean/luci-app-cpufreq
# rm -rf feeds/luci/applications/luci-app-cpufreq
# # svn co https://github.com/Boos4721/openwrt/trunk/package/lean/luci-app-cpufreq package/luci-app-cpufreq
# # svn co https://github.com/Boos4721/luci/trunk/applications/luci-app-cpufreq feeds/luci/applications/luci-app-cpufreq
# # svn co https://github.com/Boos4721/luci/trunk/applications/luci-app-cpufreq package/luci-app-cpufreq
# # svn co https://github.com/sdf8057/luci/trunk/applications/luci-app-cpufreq package/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/branches/1806/applications/luci-app-cpufreq package/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/branches/1806/applications/luci-app-cpufreq package/lean/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/branches/1806/applications/luci-app-cpufreq feeds/luci/applications/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/trunk/applications/luci-app-cpufreq package/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/trunk/applications/luci-app-cpufreq package/lean/luci-app-cpufreq
# svn co https://github.com/sdf8057/luci/trunk/applications/luci-app-cpufreq feeds/luci/applications/luci-app-cpufreq
# svn co https://github.com/Boos4721/openwrt/trunk/config config
# svn co https://github.com/Boos4721/openwrt/trunk/include include
# svn co https://github.com/Boos4721/openwrt/trunk/package package
# svn co https://github.com/Boos4721/openwrt/trunk/scripts scripts
# svn co https://github.com/Boos4721/openwrt/trunk/target target
# svn co https://github.com/Boos4721/openwrt/trunk/toolchain toolchain
# svn co https://github.com/Boos4721/openwrt/trunk/tools tools
# Passwall
rm -rf package/luci-app-passwall
rm -rf package/lean/luci-app-passwall
rm -rf feeds/luci/applications/luci-app-passwall
# svn co https://github.com/xiaorouji/openwrt-passwall/branches/luci/luci-app-passwall package/luci-app-passwall
# svn co https://github.com/xiaorouji/openwrt-passwall/trunk/shadowsocksr-libev package/shadowsocksr-libev
# svn co https://github.com/xiaorouji/openwrt-passwall/trunk/simple-obfs package/simple-obfs
# svn co https://github.com/xiaorouji/openwrt-passwall/trunk/tcping package/tcping
# svn co https://github.com/xiaorouji/openwrt-passwall/trunk/luci-app-passwall package/luci-app-passwall
# svn co https://github.com/xiaorouji/openwrt-passwall-packages/trunk/shadowsocksr-libev package/shadowsocksr-libev
# svn co https://github.com/xiaorouji/openwrt-passwall-packages/trunk/simple-obfs package/simple-obfs
# svn co https://github.com/xiaorouji/openwrt-passwall-packages/trunk/tcping package/tcping
# PassWall
# git clone --depth 1 https://github.com/xiaorouji/openwrt-passwall-packages.git passwall_packages
# git clone --depth 1 https://github.com/xiaorouji/openwrt-passwall.git luci-passwall
# PassWall2
# git clone --depth 1 https://github.com/xiaorouji/openwrt-passwall2.git luci-passwall2
# AutoCore
svn export https://github.com/immortalwrt/immortalwrt/branches/master/package/emortal/autocore package/new/autocore
sed -i 's/"getTempInfo" /"getTempInfo", "getCPUBench", "getCPUUsage" /g' package/new/autocore/files/luci-mod-status-autocore.json
rm -rf feeds/luci/modules/luci-base
rm -rf feeds/luci/modules/luci-mod-status
rm -rf feeds/packages/utils/coremark
rm -rf package/emortal/default-settings
svn export https://github.com/immortalwrt/luci/branches/master/modules/luci-base feeds/luci/modules/luci-base
svn export https://github.com/immortalwrt/luci/branches/master/modules/luci-mod-status feeds/luci/modules/luci-mod-status
svn export https://github.com/immortalwrt/packages/branches/master/utils/coremark package/new/coremark
svn export https://github.com/immortalwrt/immortalwrt/branches/master/package/emortal/default-settings package/emortal/default-settings
# svn export https://github.com/immortalwrt/immortalwrt/branches/openwrt-23.05/package/utils/mhz package/utils/mhz
# fix luci-theme-argon css
mkdir -p files/www/luci-static/argon/css
wget https://github.com/jerrykuku/luci-theme-argon/raw/master/htdocs/luci-static/argon/css/cascade.css -O files/www/luci-static/argon/css/cascade.css
wget https://github.com/jerrykuku/luci-theme-argon/raw/master/htdocs/luci-static/argon/css/dark.css -O files/www/luci-static/argon/css/dark.css