fix something

This commit is contained in:
Ing 2024-03-10 23:02:06 +08:00
parent e16be2497a
commit 7f819e9801
5 changed files with 45 additions and 39 deletions

View File

@ -13,17 +13,17 @@ This project is a system for redpills preinstallation and recovery environmen
### 鸣谢 - Credits ### 鸣谢 - Credits
* Arpl: @fbelavenuto * Arpl: @fbelavenuto
* https://github.com/fbelavenuto/arpl * https://github.com/fbelavenuto/arpl
* Redpill: @RedPill-TTG @pocopico @jim3ma * Redpill: @RedPill-TTG @pocopico @jim3ma @fbelavenuto @MoetaYuko
* https://github.com/RedPill-TTG * https://github.com/RedPill-TTG
* https://github.com/XPEnology-Community/redpill-lkm5 * https://github.com/XPEnology-Community/redpill-lkm5
* https://github.com/MoetaYuko/linux_dsm_epyc7002
* Framework: * Framework:
* https://github.com/buildroot/buildroot * https://github.com/buildroot/buildroot
* https://github.com/eudev-project/eudev * https://github.com/eudev-project/eudev
* Addons: @xbl3 @wirgen @FOXBI @arabezar @007revad * Addons: @xbl3 @wirgen @007revad @PeterSuh-Q3
* https://github.com/xbl3/synocodectool-patch (https://github.com/wirgen/synocodectool-patch) * https://github.com/xbl3/synocodectool-patch (https://github.com/wirgen/synocodectool-patch)
* https://github.com/FOXBI/ch_cpuinfo (https://github.com/arabezar/ch_cpuinfo)
* https://github.com/007revad/Synology_HDD_db * https://github.com/007revad/Synology_HDD_db
* https://github.com/007revad/Synology_enable_M2_volume * https://github.com/007revad/Synology_enable_M2_volume (base)
* Modules: @jim3ma @MoetaYuko * Modules: @jim3ma @MoetaYuko
* https://github.com/jim3ma/synology-igc * https://github.com/jim3ma/synology-igc
* https://github.com/MoetaYuko/intel-gpu-i915-backports * https://github.com/MoetaYuko/intel-gpu-i915-backports
@ -31,14 +31,17 @@ This project is a system for redpills preinstallation and recovery environmen
### 组件: ### 组件:
<b>https://github.com/wjz304/rr</b> <b>https://github.com/wjz304/rr</b>
* addons: https://github.com/wjz304/rr-addons
* modules: https://github.com/wjz304/rr-modules
* rp-lkms: https://github.com/wjz304/rr-lkms
### About GPU: ### About GPU:
* vGPU: https://blog.kkk.rs/ * vGPU:
* iGPU: https://jim.plus/ * https://blog.kkk.rs/
* iGPU: https://github.com/MoetaYuko/intel-gpu-i915-backports * https://github.com/pdbear/syno_nvidia_gpu_driver/
* iGPU:
* https://jim.plus/
* iGPU:
* https://github.com/MoetaYuko/intel-gpu-i915-backports
## 说明 - Instructions ## 说明 - Instructions
* [GUIDE](./guide.md) * [GUIDE](./guide.md)
@ -46,6 +49,7 @@ This project is a system for redpills preinstallation and recovery environmen
* [About not find DSM after "boot the loader"](https://github.com/wjz304/rr/issues/175) * [About not find DSM after "boot the loader"](https://github.com/wjz304/rr/issues/175)
* [About DT(Device Tree) and *portcfg/maxdisks](https://github.com/wjz304/rr/issues/226) * [About DT(Device Tree) and *portcfg/maxdisks](https://github.com/wjz304/rr/issues/226)
## 翻译 - Translation ## 翻译 - Translation
* 其他语言的翻译 - Language translation work: * 其他语言的翻译 - Language translation work:
```shell ```shell
@ -65,31 +69,25 @@ This project is a system for redpills preinstallation and recovery environmen
Developers who are familiar with various languages are welcome to submit PR. Developers who are familiar with various languages are welcome to submit PR.
* Translation maintenance personnel: * Translation maintenance personnel:
* en_US: @wjz304
* ko_KR: @EXP <jeong1986>
* ru_RU: @Alex TG
* zh_CN: @wjz304 * zh_CN: @wjz304
* zh_TW: @豪客幫 * zh_HK: @wjz304
* zh_TW: @March Fun <https://cyber.suma.tw/> (豪客幫)
## 教程 - Usage
* English: https://www.youtube.com/watch?v=VB67_FG5y-E
##### `(From: @NETVN82)`
* Español: https://www.youtube.com/watch?v=KC6oCcAyoV4
##### `(From: @Jay tech 2023)`
* 한국어: https://www.youtube.com/watch?v=4O7EfU6MT60
##### `(From: @pageinnet)`
* ภาษาไทย: https://www.youtube.com/watch?v=4sGrMMEQQ6I
##### `(From: @stnology)`
* 中文繁體: https://www.youtube.com/watch?v=cW2eRCjtAEs
##### `(From: @豪客幫)`
* 中文简体: https://www.bilibili.com/video/BV1jk4y1Y7B7
##### `(From: http://mi-d.cn)`
## 打赏一下 ## 打赏一下
* > ### 作者: Ing *
* > QQ群1: 21609194 [点击链接加入QQ群](https://qm.qq.com/cgi-bin/qm/qr?k=z5O89os88QEKXCbz-0gwtEz1AeQiCwk3) * ### 作者: Ing
* > QQ群2: 73119176 [点击链接加入QQ群](https://qm.qq.com/cgi-bin/qm/qr?k=6GFSrSYX2LTd9PD0r0hl_YJZsfLp53Oh) * QQ群1: 21609194 [点击链接加入QQ群](https://qm.qq.com/q/YTPvSXfeU0)
* > QQ频道: redpill2syno [点击链接加入QQ频道](https://pd.qq.com/s/5nmli9qgn) * QQ群2: 73119176 [点击链接加入QQ群](https://qm.qq.com/q/YV1B0NFvWK)
* > TG频道: redpill2syno [点击链接加入TG频道](https://t.me/redpill2syno) * QQ群3: 51929774 [点击链接加入QQ群](https://qm.qq.com/q/aVjM3Wb6KY)
* <img src="https://raw.githubusercontent.com/wjz304/wjz304/master/my/20220908134226.jpg" width="400"> * QQ群4: 49756829 [点击链接加入QQ群](https://qm.qq.com/q/9PHzmZDkqI)
* QQ频道: RR Org [点击链接加入QQ频道](https://pd.qq.com/s/aklqb0uij)
* TG频道: RR Org [点击链接加入TG频道](https://t.me/RR_Org)
* * <img src="https://raw.githubusercontent.com/wjz304/wjz304/master/my/20220908134226.jpg" width="400">

View File

@ -60,3 +60,11 @@ function readConfigArray() {
function readConfigEntriesArray() { function readConfigEntriesArray() {
yq eval '.'${1}' | explode(.) | to_entries | map([.key])[] | .[]' "${2}" 2>/dev/null yq eval '.'${1}' | explode(.) | to_entries | map([.key])[] | .[]' "${2}" 2>/dev/null
} }
###############################################################################
# Check yaml config file
# 1 - Path of yaml config file
# Returns error information
function checkConfigFile() {
yq eval "${1}" 2>&1
}

View File

@ -2,11 +2,11 @@ RR_VERSION="24.3.1"
RR_TITLE="RR v${RR_VERSION}" RR_TITLE="RR v${RR_VERSION}"
# Define paths # Define paths
# CHROOT_PATH: Defined during PC debugging.
PART1_PATH="/mnt/p1" PART1_PATH="${CHROOT_PATH}/mnt/p1"
PART2_PATH="/mnt/p2" PART2_PATH="${CHROOT_PATH}/mnt/p2"
PART3_PATH="/mnt/p3" PART3_PATH="${CHROOT_PATH}/mnt/p3"
TMP_PATH="/tmp" TMP_PATH="${CHROOT_PATH}/tmp"
UNTAR_PAT_PATH="${TMP_PATH}/pat" UNTAR_PAT_PATH="${TMP_PATH}/pat"
RAMDISK_PATH="${TMP_PATH}/ramdisk" RAMDISK_PATH="${TMP_PATH}/ramdisk"

View File

@ -1191,7 +1191,7 @@ function extractDsmFiles() {
# Check disk space left # Check disk space left
SPACELEFT=$(df --block-size=1 ${LOADER_DISK_PART3} 2>/dev/null | awk 'NR==2 {print $4}') SPACELEFT=$(df --block-size=1 ${LOADER_DISK_PART3} 2>/dev/null | awk 'NR==2 {print $4}')
# Discover remote file size # Discover remote file size
FILESIZE=$(curl -skLI --connect-timeout 10 "${PATURL}" | grep -i Content-Length | tail -n 1 | awk '{print $2}') FILESIZE=$(curl -skLI --connect-timeout 10 "${PATURL}" | grep -i Content-Length | tail -n 1 | tr -d '\r\n' | awk '{print $2}')
if [ ${FILESIZE:-0} -ge ${SPACELEFT:-0} ]; then if [ ${FILESIZE:-0} -ge ${SPACELEFT:-0} ]; then
# No disk space to download, change it to RAMDISK # No disk space to download, change it to RAMDISK
PAT_PATH="${TMP_PATH}/${PAT_FILE}" PAT_PATH="${TMP_PATH}/${PAT_FILE}"
@ -2288,7 +2288,7 @@ function editUserConfig() {
[ $? -ne 0 ] && return [ $? -ne 0 ] && return
mv -f "${TMP_PATH}/userconfig" "${USER_CONFIG_FILE}" mv -f "${TMP_PATH}/userconfig" "${USER_CONFIG_FILE}"
dos2unix "${USER_CONFIG_FILE}" dos2unix "${USER_CONFIG_FILE}"
ERRORS=$(yq eval "${USER_CONFIG_FILE}" 2>&1) ERRORS=$(checkConfigFile "${USER_CONFIG_FILE}")
[ $? -eq 0 ] && break [ $? -eq 0 ] && break
DIALOG --title "$(TEXT "Edit with caution")" \ DIALOG --title "$(TEXT "Edit with caution")" \
--msgbox "${ERRORS}" 0 0 --msgbox "${ERRORS}" 0 0

View File

@ -101,7 +101,7 @@ while read PE; do
echo "Patching with ${PF}" >>"${LOG_FILE}" 2>&1 echo "Patching with ${PF}" >>"${LOG_FILE}" 2>&1
( (
cd "${RAMDISK_PATH}" cd "${RAMDISK_PATH}"
patch -p1 -i "${PF}" >>"${LOG_FILE}" 2>&1 busybox patch -p1 -i "${PF}" >>"${LOG_FILE}" 2>&1 # busybox patch and gun patch have different processing methods and parameters.
) )
RET=$? RET=$?
[ ${RET} -eq 0 ] && break [ ${RET} -eq 0 ] && break