-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a362915
commit e5581ea
Showing
1 changed file
with
31 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
#!/bin/bash | ||
# | ||
# https://github.com/P3TERX/Actions-OpenWrt | ||
# File name: diy-part2.sh | ||
# Description: OpenWrt DIY script part 2 (After Update feeds) | ||
# | ||
# Copyright (c) 2019-2024 P3TERX <https://p3terx.com> | ||
# | ||
# This is free software, licensed under the MIT License. | ||
# See /LICENSE for more information. | ||
# | ||
|
||
# Modify default IP | ||
sed -i 's/192.168.1.1/10.10.10.100/g' package/base-files/files/bin/config_generate | ||
|
||
# Modify default theme | ||
#$sed -i 's/luci-theme-bootstrap/luci-theme-argone/g' feeds/luci/collections/luci/Makefile | ||
|
||
# Modify hostname | ||
#sed -i 's/OpenWrt/P3TERX-Router/g' package/base-files/files/bin/config_generate | ||
|
||
# x86 型号只显示 CPU 型号 | ||
sed -i 's/${g}.*/${a}${b}${c}${d}${e}${f}${hydrid}/g' package/lean/autocore/files/x86/autocore | ||
|
||
# 修改本地时间格式 | ||
sed -i 's/os.date()/os.date("%a %Y-%m-%d %H:%M:%S")/g' package/lean/autocore/files/*/index.htm | ||
|
||
# 修改版本为编译日期 | ||
date_version=$(date +"%y.%m.%d") | ||
orig_version=$(cat "package/lean/default-settings/files/zzz-default-settings" | grep DISTRIB_REVISION= | awk -F "'" '{print $2}') | ||
sed -i "s/${orig_version}/R${date_version} by EircoD/g" package/lean/default-settings/files/zzz-default-settings |