add DiskIdxMap recommended, fix netif_num

This commit is contained in:
Ing 2023-04-22 21:19:52 +08:00
parent 6796c5e905
commit 9eb9ba9f8d
6 changed files with 373 additions and 362 deletions

View File

@ -88,12 +88,9 @@ fi
# Validate netif_num # Validate netif_num
NETIF_NUM=${CMDLINE["netif_num"]} NETIF_NUM=${CMDLINE["netif_num"]}
MACS=0 NETRL_NUM=`ip link show | grep ether | wc -l`
for N in `seq 1 9`; do if [ ${NETIF_NUM} -ne ${NETRL_NUM} ]; then
[ -n "${CMDLINE["mac${N}"]}" ] && MACS=$((${MACS}+1)) echo -e "\033[1;33m*** `printf "$(TEXT "netif_num is not equal to real network card amount, set netif_num to %s")" "${NETRL_NUM}"` ***\033[0m"
done
if [ ${NETIF_NUM} -ne ${MACS} ]; then
echo -e "\033[1;33m*** `printf "$(TEXT "netif_num is not equal to macX amount, set netif_num to %s")" "${MACS}"` ***\033[0m"
CMDLINE["netif_num"]=${MACS} CMDLINE["netif_num"]=${MACS}
fi fi

View File

@ -69,8 +69,8 @@ if [ -d "${CACHE_PATH}/patch" ]; then
fi fi
# Get first MAC address # Get first MAC address
MAC=`ip link show eth0 | awk '/ether/{print$2}'` MACS=`ip link show | awk '/ether/{print$2}'`
MACF=`echo ${MAC} | sed 's/://g'` MACFS=(`echo ${MACS} | sed 's/://g'`)
# If user config file not exists, initialize it # If user config file not exists, initialize it
if [ ! -f "${USER_CONFIG_FILE}" ]; then if [ ! -f "${USER_CONFIG_FILE}" ]; then
@ -92,19 +92,25 @@ if [ ! -f "${USER_CONFIG_FILE}" ]; then
writeConfigKey "addons.acpid" "" "${USER_CONFIG_FILE}" writeConfigKey "addons.acpid" "" "${USER_CONFIG_FILE}"
writeConfigKey "modules" "{}" "${USER_CONFIG_FILE}" writeConfigKey "modules" "{}" "${USER_CONFIG_FILE}"
# Initialize with real MAC # Initialize with real MAC
writeConfigKey "cmdline.netif_num" "1" "${USER_CONFIG_FILE}" writeConfigKey "cmdline.netif_num" "${#MACFS[@]}" "${USER_CONFIG_FILE}"
writeConfigKey "cmdline.mac1" "${MACF}" "${USER_CONFIG_FILE}" for i in $(seq 1 ${#MACFS[@]}); do
writeConfigKey "cmdline.mac${i}" "${MACFS[$(expr ${i} - 1)]}" "${USER_CONFIG_FILE}"
done
fi fi
writeConfigKey "original-mac" "${MACF}" "${USER_CONFIG_FILE}" for i in $(seq 1 ${#MACFS[@]}); do
writeConfigKey "original-mac${i}" "${MACFS[$(expr ${i} - 1)]}" "${USER_CONFIG_FILE}"
done
# Set custom MAC if defined # Set custom MAC if defined
MAC1="`readConfigKey "cmdline.mac1" "${USER_CONFIG_FILE}"`" for i in $(seq 1 ${#MACFS[@]}); do
if [ -n "${MAC1}" -a "${MAC1}" != "${MACF}" ]; then MACF="`readConfigKey "cmdline.mac${i}" "${USER_CONFIG_FILE}"`"
MAC="${MAC1:0:2}:${MAC1:2:2}:${MAC1:4:2}:${MAC1:6:2}:${MAC1:8:2}:${MAC1:10:2}" if [ -n "${MACF}" -a "${MACF}" != "${MACFS[$(expr ${i} - 1)]}" ]; then
echo "`printf "$(TEXT "Setting MAC to %s")" "${MAC}"`" MAC="${MACF:0:2}:${MACF:2:2}:${MACF:4:2}:${MACF:6:2}:${MACF:8:2}:${MACF:10:2}"
ip link set dev eth0 address ${MAC} >/dev/null 2>&1 && \ echo "`printf "$(TEXT "Setting %s MAC to %s")" "eth$(expr ${i} - 1)" "${MAC}"`"
ip link set dev eth$(expr ${i} - 1) address ${MAC} >/dev/null 2>&1 && \
(/etc/init.d/S41dhcpcd restart >/dev/null 2>&1 &) || true (/etc/init.d/S41dhcpcd restart >/dev/null 2>&1 &) || true
fi fi
done
# Get the VID/PID if we are in USB # Get the VID/PID if we are in USB
VID="0x0000" VID="0x0000"
@ -177,7 +183,7 @@ while true; do
break break
fi fi
COUNT=$((${COUNT}+1)) COUNT=$((${COUNT}+1))
IP=`ip route get 1.1.1.1 2>/dev/null | awk '{print$7}'` IP=`ip route 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p' | head -1` # IP=`ip route get 1.1.1.1 2>/dev/null | awk '{print$7}'`
if [ -n "${IP}" ]; then if [ -n "${IP}" ]; then
echo -en "`printf "$(TEXT "OK\nAccess \033[1;34mhttp://%s:7681\033[0m to configure the loader via web terminal")" "${IP}"`" echo -en "`printf "$(TEXT "OK\nAccess \033[1;34mhttp://%s:7681\033[0m to configure the loader via web terminal")" "${IP}"`"
break break

View File

@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-04-16 00:15+0800\n" "POT-Creation-Date: 2023-04-22 21:11+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -17,7 +17,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
#: boot.sh:8 init.sh:159 #: boot.sh:8 init.sh:165
msgid "Loader is not configured!" msgid "Loader is not configured!"
msgstr "" msgstr ""
@ -33,12 +33,12 @@ msgstr ""
msgid "DSM zImage changed" msgid "DSM zImage changed"
msgstr "" msgstr ""
#: boot.sh:27 boot.sh:39 menu.sh:567 menu.sh:593 menu.sh:662 menu.sh:673 #: boot.sh:27 boot.sh:39 menu.sh:570 menu.sh:596 menu.sh:665 menu.sh:676
#: menu.sh:702 menu.sh:712 menu.sh:719 #: menu.sh:705 menu.sh:715 menu.sh:722
msgid "Error" msgid "Error"
msgstr "" msgstr ""
#: boot.sh:28 menu.sh:713 #: boot.sh:28 menu.sh:716
msgid "zImage not patched:\\n" msgid "zImage not patched:\\n"
msgstr "" msgstr ""
@ -46,7 +46,7 @@ msgstr ""
msgid "DSM Ramdisk changed" msgid "DSM Ramdisk changed"
msgstr "" msgstr ""
#: boot.sh:40 menu.sh:720 #: boot.sh:40 menu.sh:723
msgid "Ramdisk not patched:\\n" msgid "Ramdisk not patched:\\n"
msgstr "" msgstr ""
@ -58,35 +58,35 @@ msgstr ""
msgid "Build:" msgid "Build:"
msgstr "" msgstr ""
#: boot.sh:96 #: boot.sh:93
msgid "netif_num is not equal to macX amount, set netif_num to %s" msgid "netif_num is not equal to real network card amount, set netif_num to %s"
msgstr "" msgstr ""
#: boot.sh:117 #: boot.sh:114
msgid "Cmdline:\\n" msgid "Cmdline:\\n"
msgstr "" msgstr ""
#: boot.sh:121 #: boot.sh:118
msgid "IP" msgid "IP"
msgstr "" msgstr ""
#: boot.sh:139 #: boot.sh:136
msgid "Reboot to boot directly in DSM" msgid "Reboot to boot directly in DSM"
msgstr "" msgstr ""
#: boot.sh:144 #: boot.sh:141
msgid "Loading DSM kernel..." msgid "Loading DSM kernel..."
msgstr "" msgstr ""
#: boot.sh:148 #: boot.sh:145
msgid "Warning, running kexec with --noefi param, strange things will happen!!" msgid "Warning, running kexec with --noefi param, strange things will happen!!"
msgstr "" msgstr ""
#: boot.sh:153 #: boot.sh:150
msgid "Booting..." msgid "Booting..."
msgstr "" msgstr ""
#: boot.sh:156 #: boot.sh:153
msgid "" msgid ""
"[This interface will not be operational. Please use the http://find.synology." "[This interface will not be operational. Please use the http://find.synology."
"com/ find DSM and connect.]" "com/ find DSM and connect.]"
@ -100,57 +100,57 @@ msgstr ""
msgid "Can't mount %s" msgid "Can't mount %s"
msgstr "" msgstr ""
#: init.sh:104 #: init.sh:109
msgid "Setting MAC to %s" msgid "Setting %s MAC to %s"
msgstr "" msgstr ""
#: init.sh:117 #: init.sh:123
msgid "Loader disk neither USB or DoM" msgid "Loader disk neither USB or DoM"
msgstr "" msgstr ""
#: init.sh:125 #: init.sh:131
msgid "Loader disk:" msgid "Loader disk:"
msgstr "" msgstr ""
#: init.sh:138 #: init.sh:144
msgid "Resizing %s" msgid "Resizing %s"
msgstr "" msgstr ""
#: init.sh:149 #: init.sh:155
msgid "Loading keymap" msgid "Loading keymap"
msgstr "" msgstr ""
#: init.sh:162 #: init.sh:168
msgid "User requested edit settings." msgid "User requested edit settings."
msgstr "" msgstr ""
#: init.sh:173 #: init.sh:179
msgid "Waiting IP." msgid "Waiting IP."
msgstr "" msgstr ""
#: init.sh:176 #: init.sh:182
msgid "ERROR" msgid "ERROR"
msgstr "" msgstr ""
#: init.sh:182 #: init.sh:188
msgid "" msgid ""
"OK\\nAccess \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via " "OK\\nAccess \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via "
"web terminal" "web terminal"
msgstr "" msgstr ""
#: init.sh:191 #: init.sh:197
msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader"
msgstr "" msgstr ""
#: init.sh:193 #: init.sh:199
msgid "User config is on" msgid "User config is on"
msgstr "" msgstr ""
#: init.sh:194 #: init.sh:200
msgid "Default SSH Root password is" msgid "Default SSH Root password is"
msgstr "" msgstr ""
#: init.sh:200 #: init.sh:206
msgid "" msgid ""
"You have less than 4GB of RAM, if errors occur in loader creation, please " "You have less than 4GB of RAM, if errors occur in loader creation, please "
"increase the amount of memory." "increase the amount of memory."
@ -194,7 +194,7 @@ msgstr ""
msgid "Reconfiguring Synoinfo, Addons and Modules" msgid "Reconfiguring Synoinfo, Addons and Modules"
msgstr "" msgstr ""
#: menu.sh:187 menu.sh:236 menu.sh:355 menu.sh:458 menu.sh:860 menu.sh:1006 #: menu.sh:187 menu.sh:236 menu.sh:355 menu.sh:461 menu.sh:868 menu.sh:1014
msgid "Choose a option" msgid "Choose a option"
msgstr "" msgstr ""
@ -210,7 +210,7 @@ msgstr ""
msgid "Please enter a serial number " msgid "Please enter a serial number "
msgstr "" msgstr ""
#: menu.sh:206 menu.sh:953 menu.sh:1197 #: menu.sh:206 menu.sh:961 menu.sh:1193
msgid "Alert" msgid "Alert"
msgstr "" msgstr ""
@ -238,8 +238,8 @@ msgstr ""
msgid "Download a external addon" msgid "Download a external addon"
msgstr "" msgstr ""
#: menu.sh:242 menu.sh:352 menu.sh:454 menu.sh:750 menu.sh:865 menu.sh:1012 #: menu.sh:242 menu.sh:352 menu.sh:457 menu.sh:753 menu.sh:873 menu.sh:1020
#: menu.sh:1246 #: menu.sh:1242
msgid "Exit" msgid "Exit"
msgstr "" msgstr ""
@ -279,11 +279,11 @@ msgstr ""
msgid "please enter the complete URL to download.\\n" msgid "please enter the complete URL to download.\\n"
msgstr "" msgstr ""
#: menu.sh:319 menu.sh:549 #: menu.sh:319 menu.sh:552
msgid "Downloading %s" msgid "Downloading %s"
msgstr "" msgstr ""
#: menu.sh:322 menu.sh:559 menu.sh:622 #: menu.sh:322 menu.sh:562 menu.sh:625
msgid "Error downloading" msgid "Error downloading"
msgstr "" msgstr ""
@ -327,8 +327,8 @@ msgstr ""
msgid "Show model/build cmdline" msgid "Show model/build cmdline"
msgstr "" msgstr ""
#: menu.sh:360 menu.sh:366 menu.sh:397 menu.sh:406 menu.sh:415 menu.sh:417 #: menu.sh:360 menu.sh:366 menu.sh:399 menu.sh:408 menu.sh:417 menu.sh:419
#: menu.sh:426 #: menu.sh:429
msgid "User cmdline" msgid "User cmdline"
msgstr "" msgstr ""
@ -348,450 +348,450 @@ msgstr ""
msgid "Select cmdline to remove" msgid "Select cmdline to remove"
msgstr "" msgstr ""
#: menu.sh:398 #: menu.sh:400
msgid "Type a custom MAC address" msgid "Type a custom MAC address of %s"
msgstr "" msgstr ""
#: menu.sh:406 #: menu.sh:408
msgid "Invalid MAC" msgid "Invalid MAC"
msgstr "" msgstr ""
#: menu.sh:415 #: menu.sh:417
msgid "Changing MAC" msgid "Changing MAC"
msgstr "" msgstr ""
#: menu.sh:417 #: menu.sh:419
msgid "Renewing IP" msgid "Renewing IP"
msgstr "" msgstr ""
#: menu.sh:434 #: menu.sh:437
msgid "Model/build cmdline" msgid "Model/build cmdline"
msgstr "" msgstr ""
#: menu.sh:451 #: menu.sh:454
msgid "Add/edit a synoinfo item" msgid "Add/edit a synoinfo item"
msgstr "" msgstr ""
#: menu.sh:452 #: menu.sh:455
msgid "Delete synoinfo item(s)" msgid "Delete synoinfo item(s)"
msgstr "" msgstr ""
#: menu.sh:453 #: menu.sh:456
msgid "Show synoinfo entries" msgid "Show synoinfo entries"
msgstr "" msgstr ""
#: menu.sh:463 menu.sh:469 menu.sh:504 #: menu.sh:466 menu.sh:472 menu.sh:507
msgid "Synoinfo entries" msgid "Synoinfo entries"
msgstr "" msgstr ""
#: menu.sh:464 #: menu.sh:467
msgid "Type a name of synoinfo entry" msgid "Type a name of synoinfo entry"
msgstr "" msgstr ""
#: menu.sh:470 #: menu.sh:473
msgid "Type a value of '%s' synoinfo entry" msgid "Type a value of '%s' synoinfo entry"
msgstr "" msgstr ""
#: menu.sh:480 #: menu.sh:483
msgid "No synoinfo entries to remove" msgid "No synoinfo entries to remove"
msgstr "" msgstr ""
#: menu.sh:488 #: menu.sh:491
msgid "Select synoinfo entry to remove" msgid "Select synoinfo entry to remove"
msgstr "" msgstr ""
#: menu.sh:529 #: menu.sh:532
msgid "%s cached." msgid "%s cached."
msgstr "" msgstr ""
#: menu.sh:533 #: menu.sh:536
msgid "Cleaning cache" msgid "Cleaning cache"
msgstr "" msgstr ""
#: menu.sh:545 #: menu.sh:548
msgid "" msgid ""
"Based on the current network situation, switch to %s mirror to downloading." "Based on the current network situation, switch to %s mirror to downloading."
msgstr "" msgstr ""
#: menu.sh:560 menu.sh:623 #: menu.sh:563 menu.sh:626
msgid "Check internet or cache disk space" msgid "Check internet or cache disk space"
msgstr "" msgstr ""
#: menu.sh:565 #: menu.sh:568
msgid "Checking hash of %s: " msgid "Checking hash of %s: "
msgstr "" msgstr ""
#: menu.sh:568 #: menu.sh:571
msgid "Hash of pat not match, try again!" msgid "Hash of pat not match, try again!"
msgstr "" msgstr ""
#: menu.sh:572 menu.sh:666 menu.sh:677 menu.sh:688 #: menu.sh:575 menu.sh:669 menu.sh:680 menu.sh:691
msgid "OK" msgid "OK"
msgstr "" msgstr ""
#: menu.sh:576 #: menu.sh:579
msgid "Disassembling %s: " msgid "Disassembling %s: "
msgstr "" msgstr ""
#: menu.sh:581 #: menu.sh:584
msgid "Uncompressed tar" msgid "Uncompressed tar"
msgstr "" msgstr ""
#: menu.sh:585 #: menu.sh:588
msgid "Compressed tar" msgid "Compressed tar"
msgstr "" msgstr ""
#: menu.sh:589 #: menu.sh:592
msgid "Encrypted" msgid "Encrypted"
msgstr "" msgstr ""
#: menu.sh:594 #: menu.sh:597
msgid "" msgid ""
"Could not determine if pat file is encrypted or not, maybe corrupted, try " "Could not determine if pat file is encrypted or not, maybe corrupted, try "
"again!" "again!"
msgstr "" msgstr ""
#: menu.sh:605 #: menu.sh:608
msgid "Extractor cached." msgid "Extractor cached."
msgstr "" msgstr ""
#: menu.sh:612 #: menu.sh:615
msgid "Downloading old pat to extract synology .pat extractor..." msgid "Downloading old pat to extract synology .pat extractor..."
msgstr "" msgstr ""
#: menu.sh:634 menu.sh:654 #: menu.sh:637 menu.sh:657
msgid "Error extracting" msgid "Error extracting"
msgstr "" msgstr ""
#: menu.sh:648 menu.sh:651 #: menu.sh:651 menu.sh:654
msgid "Extracting..." msgid "Extracting..."
msgstr "" msgstr ""
#: menu.sh:658 #: menu.sh:661
msgid "Checking hash of zImage: " msgid "Checking hash of zImage: "
msgstr "" msgstr ""
#: menu.sh:663 #: menu.sh:666
msgid "Hash of zImage not match, try again!" msgid "Hash of zImage not match, try again!"
msgstr "" msgstr ""
#: menu.sh:669 #: menu.sh:672
msgid "Checking hash of ramdisk: " msgid "Checking hash of ramdisk: "
msgstr "" msgstr ""
#: menu.sh:674 #: menu.sh:677
msgid "Hash of ramdisk not match, try again!" msgid "Hash of ramdisk not match, try again!"
msgstr "" msgstr ""
#: menu.sh:680 #: menu.sh:683
msgid "Copying files: " msgid "Copying files: "
msgstr "" msgstr ""
#: menu.sh:703 #: menu.sh:706
msgid "Addon %s not found!" msgid "Addon %s not found!"
msgstr "" msgstr ""
#: menu.sh:724 menu.sh:1264 #: menu.sh:727 menu.sh:1260
msgid "Cleaning" msgid "Cleaning"
msgstr "" msgstr ""
#: menu.sh:727 #: menu.sh:730
msgid "Ready!" msgid "Ready!"
msgstr "" msgstr ""
#: menu.sh:740 #: menu.sh:743
msgid "Switch LKM version:" msgid "Switch LKM version:"
msgstr "" msgstr ""
#: menu.sh:741 menu.sh:850 menu.sh:876 menu.sh:887 menu.sh:900 menu.sh:906 #: menu.sh:744 menu.sh:858 menu.sh:884 menu.sh:895 menu.sh:908 menu.sh:914
msgid "Modules" msgid "Modules"
msgstr "" msgstr ""
#: menu.sh:744 #: menu.sh:747
msgid "Switch direct boot:" msgid "Switch direct boot:"
msgstr "" msgstr ""
#: menu.sh:746 #: menu.sh:749
msgid "Edit user config file manually" msgid "Edit user config file manually"
msgstr "" msgstr ""
#: menu.sh:747 #: menu.sh:750
msgid "Try to recovery a DSM installed system" msgid "Try to recovery a DSM installed system"
msgstr "" msgstr ""
#: menu.sh:748 #: menu.sh:751
msgid "Show SATA(s) # ports and drives" msgid "Show SATA(s) # ports and drives"
msgstr "" msgstr ""
#: menu.sh:749 #: menu.sh:752
msgid "Custom dts location:/mnt/p1/model.dts # Need rebuild" msgid "Custom dts location:/mnt/p1/model.dts # Need rebuild"
msgstr "" msgstr ""
#: menu.sh:752 #: menu.sh:755
msgid "Advanced" msgid "Advanced"
msgstr "" msgstr ""
#: menu.sh:753 menu.sh:1249 #: menu.sh:756 menu.sh:1245
msgid "Choose the option" msgid "Choose the option"
msgstr "" msgstr ""
#: menu.sh:792 #: menu.sh:798
msgid "\\nTotal of ports: %s\\n" msgid "\\nTotal of ports: %s\\n"
msgstr "" msgstr ""
#: menu.sh:793 #: menu.sh:799
msgid "" msgid ""
"\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive "
"connected." "connected."
msgstr "" msgstr ""
#: menu.sh:805 menu.sh:833 menu.sh:840 #: menu.sh:800
msgid "\\nRecommended value:"
msgstr ""
#: menu.sh:801
msgid "\\nDiskIdxMap:"
msgstr ""
#: menu.sh:813 menu.sh:841 menu.sh:848
msgid "Try recovery DSM" msgid "Try recovery DSM"
msgstr "" msgstr ""
#: menu.sh:806 #: menu.sh:814
msgid "Trying to recovery a DSM installed system" msgid "Trying to recovery a DSM installed system"
msgstr "" msgstr ""
#: menu.sh:827 #: menu.sh:835
msgid "Found a installation:\\nModel: %s\\nBuildnumber: %s" msgid "Found a installation:\\nModel: %s\\nBuildnumber: %s"
msgstr "" msgstr ""
#: menu.sh:831 #: menu.sh:839
msgid "\\nSerial: %s" msgid "\\nSerial: %s"
msgstr "" msgstr ""
#: menu.sh:841 #: menu.sh:849
msgid "Unfortunately I couldn't mount the DSM partition!" msgid "Unfortunately I couldn't mount the DSM partition!"
msgstr "" msgstr ""
#: menu.sh:851 #: menu.sh:859
msgid "Reading modules" msgid "Reading modules"
msgstr "" msgstr ""
#: menu.sh:861 #: menu.sh:869
msgid "Show selected modules" msgid "Show selected modules"
msgstr "" msgstr ""
#: menu.sh:862 #: menu.sh:870
msgid "Select all modules" msgid "Select all modules"
msgstr "" msgstr ""
#: menu.sh:863 #: menu.sh:871
msgid "Deselect all modules" msgid "Deselect all modules"
msgstr "" msgstr ""
#: menu.sh:864 #: menu.sh:872
msgid "Choose modules to include" msgid "Choose modules to include"
msgstr "" msgstr ""
#: menu.sh:873 #: menu.sh:881
msgid "User modules" msgid "User modules"
msgstr "" msgstr ""
#: menu.sh:877 #: menu.sh:885
msgid "Selecting all modules" msgid "Selecting all modules"
msgstr "" msgstr ""
#: menu.sh:888 #: menu.sh:896
msgid "Deselecting all modules" msgid "Deselecting all modules"
msgstr "" msgstr ""
#: menu.sh:901 #: menu.sh:909
msgid "Select modules to include" msgid "Select modules to include"
msgstr "" msgstr ""
#: menu.sh:907 #: menu.sh:915
msgid "Writing to user config" msgid "Writing to user config"
msgstr "" msgstr ""
#: menu.sh:928 #: menu.sh:936
msgid "Edit with caution" msgid "Edit with caution"
msgstr "" msgstr ""
#: menu.sh:934 #: menu.sh:942
msgid "Invalid YAML format" msgid "Invalid YAML format"
msgstr "" msgstr ""
#: menu.sh:954 #: menu.sh:962
msgid "Config changed, would you like to rebuild the loader?" msgid "Config changed, would you like to rebuild the loader?"
msgstr "" msgstr ""
#: menu.sh:966 menu.sh:1240 #: menu.sh:974 menu.sh:1236
msgid "Choose a language" msgid "Choose a language"
msgstr "" msgstr ""
#: menu.sh:979 #: menu.sh:987
msgid "Choose a layout" msgid "Choose a layout"
msgstr "" msgstr ""
#: menu.sh:989 #: menu.sh:997
msgid "Choice a keymap" msgid "Choice a keymap"
msgstr "" msgstr ""
#: menu.sh:1007 menu.sh:1017 menu.sh:1022 menu.sh:1028 menu.sh:1032 #: menu.sh:1015 menu.sh:1025 menu.sh:1030 menu.sh:1036 menu.sh:1040
#: menu.sh:1037 menu.sh:1043 menu.sh:1050 menu.sh:1054 menu.sh:1071 #: menu.sh:1045 menu.sh:1051 menu.sh:1058 menu.sh:1062 menu.sh:1079
msgid "Update arpl" msgid "Update arpl"
msgstr "" msgstr ""
#: menu.sh:1008 menu.sh:1079 menu.sh:1083 menu.sh:1087 menu.sh:1091 #: menu.sh:1016 menu.sh:1087 menu.sh:1091 menu.sh:1095 menu.sh:1099
#: menu.sh:1095 menu.sh:1100 menu.sh:1110 #: menu.sh:1103 menu.sh:1108 menu.sh:1118
msgid "Update addons" msgid "Update addons"
msgstr "" msgstr ""
#: menu.sh:1009 menu.sh:1115 menu.sh:1119 menu.sh:1123 menu.sh:1127 #: menu.sh:1017 menu.sh:1123 menu.sh:1127 menu.sh:1131 menu.sh:1135
#: menu.sh:1131 menu.sh:1136 #: menu.sh:1139 menu.sh:1144
msgid "Update LKMs" msgid "Update LKMs"
msgstr "" msgstr ""
#: menu.sh:1010 #: menu.sh:1018
msgid "Update modules" msgid "Update modules"
msgstr "" msgstr ""
#: menu.sh:1011 #: menu.sh:1019
msgid "Set proxy server" msgid "Set proxy server"
msgstr "" msgstr ""
#: menu.sh:1018 menu.sh:1080 menu.sh:1116 menu.sh:1153 #: menu.sh:1026 menu.sh:1088 menu.sh:1124 menu.sh:1149
msgid "Checking last version" msgid "Checking last version"
msgstr "" msgstr ""
#: menu.sh:1023 menu.sh:1084 menu.sh:1120 menu.sh:1157 #: menu.sh:1031 menu.sh:1092 menu.sh:1128 menu.sh:1153
msgid "Error checking new version" msgid "Error checking new version"
msgstr "" msgstr ""
#: menu.sh:1029 #: menu.sh:1037
msgid "No new version. Actual version is %s\\nForce update?" msgid "No new version. Actual version is %s\\nForce update?"
msgstr "" msgstr ""
#: menu.sh:1033 #: menu.sh:1041
msgid "Downloading last version %s" msgid "Downloading last version %s"
msgstr "" msgstr ""
#: menu.sh:1038 #: menu.sh:1046
msgid "Error downloading update file" msgid "Error downloading update file"
msgstr "" msgstr ""
#: menu.sh:1044 #: menu.sh:1052
msgid "Error extracting update file" msgid "Error extracting update file"
msgstr "" msgstr ""
#: menu.sh:1051 #: menu.sh:1059
msgid "Checksum do not match!" msgid "Checksum do not match!"
msgstr "" msgstr ""
#: menu.sh:1055 #: menu.sh:1063
msgid "Installing new files" msgid "Installing new files"
msgstr "" msgstr ""
#: menu.sh:1072 #: menu.sh:1080
msgid "Arpl updated with success to %s!\\nReboot?" msgid "Arpl updated with success to %s!\\nReboot?"
msgstr "" msgstr ""
#: menu.sh:1088 menu.sh:1124 #: menu.sh:1096 menu.sh:1132 menu.sh:1158
msgid "Downloading last version" msgid "Downloading last version"
msgstr "" msgstr ""
#: menu.sh:1092 #: menu.sh:1100
msgid "Error downloading new version" msgid "Error downloading new version"
msgstr "" msgstr ""
#: menu.sh:1096 menu.sh:1132 #: menu.sh:1104 menu.sh:1140
msgid "Extracting last version" msgid "Extracting last version"
msgstr "" msgstr ""
#: menu.sh:1101 #: menu.sh:1109
msgid "Installing new addons" msgid "Installing new addons"
msgstr "" msgstr ""
#: menu.sh:1111 #: menu.sh:1119
msgid "Addons updated with success!" msgid "Addons updated with success!"
msgstr "" msgstr ""
#: menu.sh:1128 #: menu.sh:1136 menu.sh:1162
msgid "Error downloading last version" msgid "Error downloading last version"
msgstr "" msgstr ""
#: menu.sh:1137 #: menu.sh:1145
msgid "LKMs updated with success!" msgid "LKMs updated with success!"
msgstr "" msgstr ""
#: menu.sh:1152 menu.sh:1156 menu.sh:1161 menu.sh:1165 menu.sh:1180 #: menu.sh:1148 menu.sh:1152 menu.sh:1157 menu.sh:1161 menu.sh:1176
msgid "Update Modules" msgid "Update Modules"
msgstr "" msgstr ""
#: menu.sh:1162 #: menu.sh:1177
msgid "Downloading %s modules"
msgstr ""
#: menu.sh:1166
msgid "Error downloading %s.tgz"
msgstr ""
#: menu.sh:1181
msgid "Modules updated with success!" msgid "Modules updated with success!"
msgstr "" msgstr ""
#: menu.sh:1186 #: menu.sh:1182
msgid "Set Proxy Server" msgid "Set Proxy Server"
msgstr "" msgstr ""
#: menu.sh:1187 #: menu.sh:1183
msgid "Please enter a proxy server url" msgid "Please enter a proxy server url"
msgstr "" msgstr ""
#: menu.sh:1198 #: menu.sh:1194
msgid "Invalid proxy server url, continue?" msgid "Invalid proxy server url, continue?"
msgstr "" msgstr ""
#: menu.sh:1221 #: menu.sh:1217
msgid "Choose a model" msgid "Choose a model"
msgstr "" msgstr ""
#: menu.sh:1223 #: menu.sh:1219
msgid "Choose a Build Number" msgid "Choose a Build Number"
msgstr "" msgstr ""
#: menu.sh:1224 #: menu.sh:1220
msgid "Choose a serial number" msgid "Choose a serial number"
msgstr "" msgstr ""
#: menu.sh:1226 #: menu.sh:1222
msgid "Addons" msgid "Addons"
msgstr "" msgstr ""
#: menu.sh:1227 #: menu.sh:1223
msgid "Cmdline menu" msgid "Cmdline menu"
msgstr "" msgstr ""
#: menu.sh:1228 #: menu.sh:1224
msgid "Synoinfo menu" msgid "Synoinfo menu"
msgstr "" msgstr ""
#: menu.sh:1231 #: menu.sh:1227
msgid "Advanced menu" msgid "Advanced menu"
msgstr "" msgstr ""
#: menu.sh:1234 #: menu.sh:1230
msgid "Build the loader" msgid "Build the loader"
msgstr "" msgstr ""
#: menu.sh:1238 #: menu.sh:1234
msgid "Boot the loader" msgid "Boot the loader"
msgstr "" msgstr ""
#: menu.sh:1241 #: menu.sh:1237
msgid "Choose a keymap" msgid "Choose a keymap"
msgstr "" msgstr ""
#: menu.sh:1243 #: menu.sh:1239
msgid "Clean disk cache" msgid "Clean disk cache"
msgstr "" msgstr ""
#: menu.sh:1245 #: menu.sh:1241
msgid "Update menu" msgid "Update menu"
msgstr "" msgstr ""
#: menu.sh:1271 #: menu.sh:1267
msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu"
msgstr "" msgstr ""

View File

@ -7,8 +7,8 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: arpl-i18n\n" "Project-Id-Version: arpl-i18n\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-04-16 00:15+0800\n" "POT-Creation-Date: 2023-04-22 21:11+0800\n"
"PO-Revision-Date: 2023-04-16 00:16+0800\n" "PO-Revision-Date: 2023-04-22 21:11+0800\n"
"Last-Translator: ing <wjz304@qq.com>\n" "Last-Translator: ing <wjz304@qq.com>\n"
"Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n" "Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n"
"Language: zh_CN\n" "Language: zh_CN\n"
@ -16,7 +16,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
#: boot.sh:8 init.sh:159 #: boot.sh:8 init.sh:165
msgid "Loader is not configured!" msgid "Loader is not configured!"
msgstr "引导未配置" msgstr "引导未配置"
@ -32,12 +32,12 @@ msgstr "引导"
msgid "DSM zImage changed" msgid "DSM zImage changed"
msgstr "DSM zImage 已更改" msgstr "DSM zImage 已更改"
#: boot.sh:27 boot.sh:39 menu.sh:567 menu.sh:593 menu.sh:662 menu.sh:673 #: boot.sh:27 boot.sh:39 menu.sh:570 menu.sh:596 menu.sh:665 menu.sh:676
#: menu.sh:702 menu.sh:712 menu.sh:719 #: menu.sh:705 menu.sh:715 menu.sh:722
msgid "Error" msgid "Error"
msgstr "错误" msgstr "错误"
#: boot.sh:28 menu.sh:713 #: boot.sh:28 menu.sh:716
msgid "zImage not patched:\\n" msgid "zImage not patched:\\n"
msgstr "zImage打补丁失败:\\n" msgstr "zImage打补丁失败:\\n"
@ -45,7 +45,7 @@ msgstr "zImage打补丁失败:\\n"
msgid "DSM Ramdisk changed" msgid "DSM Ramdisk changed"
msgstr "DSM Ramdisk 已更改" msgstr "DSM Ramdisk 已更改"
#: boot.sh:40 menu.sh:720 #: boot.sh:40 menu.sh:723
msgid "Ramdisk not patched:\\n" msgid "Ramdisk not patched:\\n"
msgstr "Ramdisk打补丁失败:\\n" msgstr "Ramdisk打补丁失败:\\n"
@ -57,35 +57,35 @@ msgstr "型号: "
msgid "Build:" msgid "Build:"
msgstr "版本: " msgstr "版本: "
#: boot.sh:96 #: boot.sh:93
msgid "netif_num is not equal to macX amount, set netif_num to %s" msgid "netif_num is not equal to real network card amount, set netif_num to %s"
msgstr "netif_num不等于macX将netif_num设置为%s" msgstr "netif_num不等于真实网卡数, 将netif_num设置为%s"
#: boot.sh:117 #: boot.sh:114
msgid "Cmdline:\\n" msgid "Cmdline:\\n"
msgstr "Cmdline:\\n" msgstr "Cmdline:\\n"
#: boot.sh:121 #: boot.sh:118
msgid "IP" msgid "IP"
msgstr "IP" msgstr "IP"
#: boot.sh:139 #: boot.sh:136
msgid "Reboot to boot directly in DSM" msgid "Reboot to boot directly in DSM"
msgstr "重启并直接进入DSM引导" msgstr "重启并直接进入DSM引导"
#: boot.sh:144 #: boot.sh:141
msgid "Loading DSM kernel..." msgid "Loading DSM kernel..."
msgstr "加载 DSM kernel..." msgstr "加载 DSM kernel..."
#: boot.sh:148 #: boot.sh:145
msgid "Warning, running kexec with --noefi param, strange things will happen!!" msgid "Warning, running kexec with --noefi param, strange things will happen!!"
msgstr "警告, 使用'--noefi'参数运行'kexec', 可能有不好的事情发生!!" msgstr "警告, 使用'--noefi'参数运行'kexec', 可能有不好的事情发生!!"
#: boot.sh:153 #: boot.sh:150
msgid "Booting..." msgid "Booting..."
msgstr "引导中..." msgstr "引导中..."
#: boot.sh:156 #: boot.sh:153
msgid "" msgid ""
"[This interface will not be operational. Please use the http://find.synology." "[This interface will not be operational. Please use the http://find.synology."
"com/ find DSM and connect.]" "com/ find DSM and connect.]"
@ -99,57 +99,57 @@ msgstr "引导磁盘未找到"
msgid "Can't mount %s" msgid "Can't mount %s"
msgstr "挂载 %s 失败" msgstr "挂载 %s 失败"
#: init.sh:104 #: init.sh:109
msgid "Setting MAC to %s" msgid "Setting %s MAC to %s"
msgstr "设置MAC为" msgstr "设置 %s 的MAC为 %s"
#: init.sh:117 #: init.sh:123
msgid "Loader disk neither USB or DoM" msgid "Loader disk neither USB or DoM"
msgstr "引导磁盘仅支持 USB 或者 DoM" msgstr "引导磁盘仅支持 USB 或者 DoM"
#: init.sh:125 #: init.sh:131
msgid "Loader disk:" msgid "Loader disk:"
msgstr "引导盘:" msgstr "引导盘:"
#: init.sh:138 #: init.sh:144
msgid "Resizing %s" msgid "Resizing %s"
msgstr "重置 %s 大小" msgstr "重置 %s 大小"
#: init.sh:149 #: init.sh:155
msgid "Loading keymap" msgid "Loading keymap"
msgstr "加载keymap" msgstr "加载keymap"
#: init.sh:162 #: init.sh:168
msgid "User requested edit settings." msgid "User requested edit settings."
msgstr "用户触发编辑设置" msgstr "用户触发编辑设置"
#: init.sh:173 #: init.sh:179
msgid "Waiting IP." msgid "Waiting IP."
msgstr "获取Ip" msgstr "获取Ip"
#: init.sh:176 #: init.sh:182
msgid "ERROR" msgid "ERROR"
msgstr "错误" msgstr "错误"
#: init.sh:182 #: init.sh:188
msgid "" msgid ""
"OK\\nAccess \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via " "OK\\nAccess \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via "
"web terminal" "web terminal"
msgstr "OK\\n访问 \\033[1;34mhttp://%s:7681\\033[0m 进入WEB终端进行配置" msgstr "OK\\n访问 \\033[1;34mhttp://%s:7681\\033[0m 进入WEB终端进行配置"
#: init.sh:191 #: init.sh:197
msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader"
msgstr "执行 \\033[1;32mmenu.sh\\033[0m 进入设置菜单" msgstr "执行 \\033[1;32mmenu.sh\\033[0m 进入设置菜单"
#: init.sh:193 #: init.sh:199
msgid "User config is on" msgid "User config is on"
msgstr "用户配置文件位于" msgstr "用户配置文件位于"
#: init.sh:194 #: init.sh:200
msgid "Default SSH Root password is" msgid "Default SSH Root password is"
msgstr "默认SSH的root密码为" msgstr "默认SSH的root密码为"
#: init.sh:200 #: init.sh:206
msgid "" msgid ""
"You have less than 4GB of RAM, if errors occur in loader creation, please " "You have less than 4GB of RAM, if errors occur in loader creation, please "
"increase the amount of memory." "increase the amount of memory."
@ -193,7 +193,7 @@ msgstr "该版本不支持UEFI启动, 请选择其他版本或者切换启动模
msgid "Reconfiguring Synoinfo, Addons and Modules" msgid "Reconfiguring Synoinfo, Addons and Modules"
msgstr "重新配置 Syninfo, 插件和模块" msgstr "重新配置 Syninfo, 插件和模块"
#: menu.sh:187 menu.sh:236 menu.sh:355 menu.sh:458 menu.sh:860 menu.sh:1006 #: menu.sh:187 menu.sh:236 menu.sh:355 menu.sh:461 menu.sh:868 menu.sh:1014
msgid "Choose a option" msgid "Choose a option"
msgstr "设置" msgstr "设置"
@ -209,7 +209,7 @@ msgstr "输入SN"
msgid "Please enter a serial number " msgid "Please enter a serial number "
msgstr "请输入SN " msgstr "请输入SN "
#: menu.sh:206 menu.sh:953 menu.sh:1197 #: menu.sh:206 menu.sh:961 menu.sh:1193
msgid "Alert" msgid "Alert"
msgstr "警告" msgstr "警告"
@ -237,8 +237,8 @@ msgstr "显示所有可用插件"
msgid "Download a external addon" msgid "Download a external addon"
msgstr "下载外部插件" msgstr "下载外部插件"
#: menu.sh:242 menu.sh:352 menu.sh:454 menu.sh:750 menu.sh:865 menu.sh:1012 #: menu.sh:242 menu.sh:352 menu.sh:457 menu.sh:753 menu.sh:873 menu.sh:1020
#: menu.sh:1246 #: menu.sh:1242
msgid "Exit" msgid "Exit"
msgstr "退出" msgstr "退出"
@ -278,11 +278,11 @@ msgstr "可用插件"
msgid "please enter the complete URL to download.\\n" msgid "please enter the complete URL to download.\\n"
msgstr "请输入下载URL.\\n" msgstr "请输入下载URL.\\n"
#: menu.sh:319 menu.sh:549 #: menu.sh:319 menu.sh:552
msgid "Downloading %s" msgid "Downloading %s"
msgstr "下载 %s 中" msgstr "下载 %s 中"
#: menu.sh:322 menu.sh:559 menu.sh:622 #: menu.sh:322 menu.sh:562 menu.sh:625
msgid "Error downloading" msgid "Error downloading"
msgstr "下载失败" msgstr "下载失败"
@ -326,8 +326,8 @@ msgstr "显示用户cmdline参数"
msgid "Show model/build cmdline" msgid "Show model/build cmdline"
msgstr "显示型号默认cmdline参数" msgstr "显示型号默认cmdline参数"
#: menu.sh:360 menu.sh:366 menu.sh:397 menu.sh:406 menu.sh:415 menu.sh:417 #: menu.sh:360 menu.sh:366 menu.sh:399 menu.sh:408 menu.sh:417 menu.sh:419
#: menu.sh:426 #: menu.sh:429
msgid "User cmdline" msgid "User cmdline"
msgstr "用户cmdline参数" msgstr "用户cmdline参数"
@ -347,450 +347,450 @@ msgstr "没有用户参数被删除"
msgid "Select cmdline to remove" msgid "Select cmdline to remove"
msgstr "选择要删除的参数" msgstr "选择要删除的参数"
#: menu.sh:398 #: menu.sh:400
msgid "Type a custom MAC address" msgid "Type a custom MAC address of %s"
msgstr "输入自定义MAC地址" msgstr "输入 %s 的自定义MAC地址"
#: menu.sh:406 #: menu.sh:408
msgid "Invalid MAC" msgid "Invalid MAC"
msgstr "无效的MAC" msgstr "无效的MAC"
#: menu.sh:415 #: menu.sh:417
msgid "Changing MAC" msgid "Changing MAC"
msgstr "修改MAC" msgstr "修改MAC"
#: menu.sh:417 #: menu.sh:419
msgid "Renewing IP" msgid "Renewing IP"
msgstr "刷新IP" msgstr "刷新IP"
#: menu.sh:434 #: menu.sh:437
msgid "Model/build cmdline" msgid "Model/build cmdline"
msgstr "型号默认cmdline参数" msgstr "型号默认cmdline参数"
#: menu.sh:451 #: menu.sh:454
msgid "Add/edit a synoinfo item" msgid "Add/edit a synoinfo item"
msgstr "添加/编辑Synoinfo参数" msgstr "添加/编辑Synoinfo参数"
#: menu.sh:452 #: menu.sh:455
msgid "Delete synoinfo item(s)" msgid "Delete synoinfo item(s)"
msgstr "删除Synoinfo参数(s)" msgstr "删除Synoinfo参数(s)"
#: menu.sh:453 #: menu.sh:456
msgid "Show synoinfo entries" msgid "Show synoinfo entries"
msgstr "显示Synoinfo参数" msgstr "显示Synoinfo参数"
#: menu.sh:463 menu.sh:469 menu.sh:504 #: menu.sh:466 menu.sh:472 menu.sh:507
msgid "Synoinfo entries" msgid "Synoinfo entries"
msgstr "Synoinfo参数" msgstr "Synoinfo参数"
#: menu.sh:464 #: menu.sh:467
msgid "Type a name of synoinfo entry" msgid "Type a name of synoinfo entry"
msgstr "输入参数的名称" msgstr "输入参数的名称"
#: menu.sh:470 #: menu.sh:473
msgid "Type a value of '%s' synoinfo entry" msgid "Type a value of '%s' synoinfo entry"
msgstr "输入 '%s' 参数的值" msgstr "输入 '%s' 参数的值"
#: menu.sh:480 #: menu.sh:483
msgid "No synoinfo entries to remove" msgid "No synoinfo entries to remove"
msgstr "没有Synoinfo参数被删除" msgstr "没有Synoinfo参数被删除"
#: menu.sh:488 #: menu.sh:491
msgid "Select synoinfo entry to remove" msgid "Select synoinfo entry to remove"
msgstr "选择要删除的参数" msgstr "选择要删除的参数"
#: menu.sh:529 #: menu.sh:532
msgid "%s cached." msgid "%s cached."
msgstr "%s 已缓存." msgstr "%s 已缓存."
#: menu.sh:533 #: menu.sh:536
msgid "Cleaning cache" msgid "Cleaning cache"
msgstr "清除缓存" msgstr "清除缓存"
#: menu.sh:545 #: menu.sh:548
msgid "" msgid ""
"Based on the current network situation, switch to %s mirror to downloading." "Based on the current network situation, switch to %s mirror to downloading."
msgstr "根据当前的网络状况, 已切换到 %s 镜像服务器进行下载." msgstr "根据当前的网络状况, 已切换到 %s 镜像服务器进行下载."
#: menu.sh:560 menu.sh:623 #: menu.sh:563 menu.sh:626
msgid "Check internet or cache disk space" msgid "Check internet or cache disk space"
msgstr "请检查internet或磁盘空间" msgstr "请检查internet或磁盘空间"
#: menu.sh:565 #: menu.sh:568
msgid "Checking hash of %s: " msgid "Checking hash of %s: "
msgstr "检查 %s 的 hash: " msgstr "检查 %s 的 hash: "
#: menu.sh:568 #: menu.sh:571
msgid "Hash of pat not match, try again!" msgid "Hash of pat not match, try again!"
msgstr "pat的Hash不匹配, 请重试!" msgstr "pat的Hash不匹配, 请重试!"
#: menu.sh:572 menu.sh:666 menu.sh:677 menu.sh:688 #: menu.sh:575 menu.sh:669 menu.sh:680 menu.sh:691
msgid "OK" msgid "OK"
msgstr "OK" msgstr "OK"
#: menu.sh:576 #: menu.sh:579
msgid "Disassembling %s: " msgid "Disassembling %s: "
msgstr "解压 %s: " msgstr "解压 %s: "
#: menu.sh:581 #: menu.sh:584
msgid "Uncompressed tar" msgid "Uncompressed tar"
msgstr "未压缩tar" msgstr "未压缩tar"
#: menu.sh:585 #: menu.sh:588
msgid "Compressed tar" msgid "Compressed tar"
msgstr "压缩tar" msgstr "压缩tar"
#: menu.sh:589 #: menu.sh:592
msgid "Encrypted" msgid "Encrypted"
msgstr "已加密" msgstr "已加密"
#: menu.sh:594 #: menu.sh:597
msgid "" msgid ""
"Could not determine if pat file is encrypted or not, maybe corrupted, try " "Could not determine if pat file is encrypted or not, maybe corrupted, try "
"again!" "again!"
msgstr "无法确定pat文件是否加密, 可能已损坏, 请重试!" msgstr "无法确定pat文件是否加密, 可能已损坏, 请重试!"
#: menu.sh:605 #: menu.sh:608
msgid "Extractor cached." msgid "Extractor cached."
msgstr "已存在解密程序." msgstr "已存在解密程序."
#: menu.sh:612 #: menu.sh:615
msgid "Downloading old pat to extract synology .pat extractor..." msgid "Downloading old pat to extract synology .pat extractor..."
msgstr "下载旧 pat, 提取 .pat 解密程序中..." msgstr "下载旧 pat, 提取 .pat 解密程序中..."
#: menu.sh:634 menu.sh:654 #: menu.sh:637 menu.sh:657
msgid "Error extracting" msgid "Error extracting"
msgstr "解压失败" msgstr "解压失败"
#: menu.sh:648 menu.sh:651 #: menu.sh:651 menu.sh:654
msgid "Extracting..." msgid "Extracting..."
msgstr "解压中..." msgstr "解压中..."
#: menu.sh:658 #: menu.sh:661
msgid "Checking hash of zImage: " msgid "Checking hash of zImage: "
msgstr "检查 zImage 的 hash: " msgstr "检查 zImage 的 hash: "
#: menu.sh:663 #: menu.sh:666
msgid "Hash of zImage not match, try again!" msgid "Hash of zImage not match, try again!"
msgstr "zImage的Hash不匹配, 请重试!" msgstr "zImage的Hash不匹配, 请重试!"
#: menu.sh:669 #: menu.sh:672
msgid "Checking hash of ramdisk: " msgid "Checking hash of ramdisk: "
msgstr "检查 ramdisk 的 hash: " msgstr "检查 ramdisk 的 hash: "
#: menu.sh:674 #: menu.sh:677
msgid "Hash of ramdisk not match, try again!" msgid "Hash of ramdisk not match, try again!"
msgstr "ramdisk的Hash不匹配, 请重试!" msgstr "ramdisk的Hash不匹配, 请重试!"
#: menu.sh:680 #: menu.sh:683
msgid "Copying files: " msgid "Copying files: "
msgstr "拷贝文件: " msgstr "拷贝文件: "
#: menu.sh:703 #: menu.sh:706
msgid "Addon %s not found!" msgid "Addon %s not found!"
msgstr "插件 %s 未找到!" msgstr "插件 %s 未找到!"
#: menu.sh:724 menu.sh:1264 #: menu.sh:727 menu.sh:1260
msgid "Cleaning" msgid "Cleaning"
msgstr "清除中" msgstr "清除中"
#: menu.sh:727 #: menu.sh:730
msgid "Ready!" msgid "Ready!"
msgstr "已就绪!" msgstr "已就绪!"
#: menu.sh:740 #: menu.sh:743
msgid "Switch LKM version:" msgid "Switch LKM version:"
msgstr "选择LKM版本:" msgstr "选择LKM版本:"
#: menu.sh:741 menu.sh:850 menu.sh:876 menu.sh:887 menu.sh:900 menu.sh:906 #: menu.sh:744 menu.sh:858 menu.sh:884 menu.sh:895 menu.sh:908 menu.sh:914
msgid "Modules" msgid "Modules"
msgstr "模块" msgstr "模块"
#: menu.sh:744 #: menu.sh:747
msgid "Switch direct boot:" msgid "Switch direct boot:"
msgstr "切换直接启动:" msgstr "切换直接启动:"
#: menu.sh:746 #: menu.sh:749
msgid "Edit user config file manually" msgid "Edit user config file manually"
msgstr "编辑用户配置文件" msgstr "编辑用户配置文件"
#: menu.sh:747 #: menu.sh:750
msgid "Try to recovery a DSM installed system" msgid "Try to recovery a DSM installed system"
msgstr "尝试恢复已安装DSM的系统" msgstr "尝试恢复已安装DSM的系统"
#: menu.sh:748 #: menu.sh:751
msgid "Show SATA(s) # ports and drives" msgid "Show SATA(s) # ports and drives"
msgstr "显示SATA(s) # 端口和驱动器" msgstr "显示SATA(s) # 端口和驱动器"
#: menu.sh:749 #: menu.sh:752
msgid "Custom dts location:/mnt/p1/model.dts # Need rebuild" msgid "Custom dts location:/mnt/p1/model.dts # Need rebuild"
msgstr "自定义 dts 文件位置:/mnt/p1/model.dts # 需要重新编译" msgstr "自定义 dts 文件位置:/mnt/p1/model.dts # 需要重新编译"
#: menu.sh:752 #: menu.sh:755
msgid "Advanced" msgid "Advanced"
msgstr "高级" msgstr "高级"
#: menu.sh:753 menu.sh:1249 #: menu.sh:756 menu.sh:1245
msgid "Choose the option" msgid "Choose the option"
msgstr "设置" msgstr "设置"
#: menu.sh:792 #: menu.sh:798
msgid "\\nTotal of ports: %s\\n" msgid "\\nTotal of ports: %s\\n"
msgstr "\\n端口总数: %s\\n" msgstr "\\n端口总数: %s\\n"
#: menu.sh:793 #: menu.sh:799
msgid "" msgid ""
"\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive "
"connected." "connected."
msgstr "\\n\\Z1红色\\Zn 为模拟端口, \\Z2\\Zb绿色\\Zn 为已驱动的物理端口." msgstr "\\n\\Z1红色\\Zn 为模拟端口, \\Z2\\Zb绿色\\Zn 为已驱动的物理端口."
#: menu.sh:805 menu.sh:833 menu.sh:840 #: menu.sh:800
msgid "\\nRecommended value:"
msgstr "\\n建议值:"
#: menu.sh:801
msgid "\\nDiskIdxMap:"
msgstr "\\nDiskIdxMap:"
#: menu.sh:813 menu.sh:841 menu.sh:848
msgid "Try recovery DSM" msgid "Try recovery DSM"
msgstr "尝试恢复DSM系统" msgstr "尝试恢复DSM系统"
#: menu.sh:806 #: menu.sh:814
msgid "Trying to recovery a DSM installed system" msgid "Trying to recovery a DSM installed system"
msgstr "尝试恢复已安装的DSM系统中" msgstr "尝试恢复已安装的DSM系统中"
#: menu.sh:827 #: menu.sh:835
msgid "Found a installation:\\nModel: %s\\nBuildnumber: %s" msgid "Found a installation:\\nModel: %s\\nBuildnumber: %s"
msgstr "找到已安装:\\n型号: %s\\n版本: %s" msgstr "找到已安装:\\n型号: %s\\n版本: %s"
#: menu.sh:831 #: menu.sh:839
msgid "\\nSerial: %s" msgid "\\nSerial: %s"
msgstr "\\nSN: %s" msgstr "\\nSN: %s"
#: menu.sh:841 #: menu.sh:849
msgid "Unfortunately I couldn't mount the DSM partition!" msgid "Unfortunately I couldn't mount the DSM partition!"
msgstr "很遗憾, 我无法挂载DSM分区!" msgstr "很遗憾, 我无法挂载DSM分区!"
#: menu.sh:851 #: menu.sh:859
msgid "Reading modules" msgid "Reading modules"
msgstr "读取模块中" msgstr "读取模块中"
#: menu.sh:861 #: menu.sh:869
msgid "Show selected modules" msgid "Show selected modules"
msgstr "显示已加载的模块" msgstr "显示已加载的模块"
#: menu.sh:862 #: menu.sh:870
msgid "Select all modules" msgid "Select all modules"
msgstr "选择所有模块" msgstr "选择所有模块"
#: menu.sh:863 #: menu.sh:871
msgid "Deselect all modules" msgid "Deselect all modules"
msgstr "取消所有模块" msgstr "取消所有模块"
#: menu.sh:864 #: menu.sh:872
msgid "Choose modules to include" msgid "Choose modules to include"
msgstr "选择要加载的模块" msgstr "选择要加载的模块"
#: menu.sh:873 #: menu.sh:881
msgid "User modules" msgid "User modules"
msgstr "模块" msgstr "模块"
#: menu.sh:877 #: menu.sh:885
msgid "Selecting all modules" msgid "Selecting all modules"
msgstr "全选所有模块" msgstr "全选所有模块"
#: menu.sh:888 #: menu.sh:896
msgid "Deselecting all modules" msgid "Deselecting all modules"
msgstr "取消所有模块" msgstr "取消所有模块"
#: menu.sh:901 #: menu.sh:909
msgid "Select modules to include" msgid "Select modules to include"
msgstr "选择要加载的插件" msgstr "选择要加载的插件"
#: menu.sh:907 #: menu.sh:915
msgid "Writing to user config" msgid "Writing to user config"
msgstr "写入用户配置" msgstr "写入用户配置"
#: menu.sh:928 #: menu.sh:936
msgid "Edit with caution" msgid "Edit with caution"
msgstr "请谨慎编辑" msgstr "请谨慎编辑"
#: menu.sh:934 #: menu.sh:942
msgid "Invalid YAML format" msgid "Invalid YAML format"
msgstr "无效的YAML格式" msgstr "无效的YAML格式"
#: menu.sh:954 #: menu.sh:962
msgid "Config changed, would you like to rebuild the loader?" msgid "Config changed, would you like to rebuild the loader?"
msgstr "配置已更改, 是否重新编译引导?" msgstr "配置已更改, 是否重新编译引导?"
#: menu.sh:966 menu.sh:1240 #: menu.sh:974 menu.sh:1236
msgid "Choose a language" msgid "Choose a language"
msgstr "选择语言" msgstr "选择语言"
#: menu.sh:979 #: menu.sh:987
msgid "Choose a layout" msgid "Choose a layout"
msgstr "选择布局" msgstr "选择布局"
#: menu.sh:989 #: menu.sh:997
msgid "Choice a keymap" msgid "Choice a keymap"
msgstr "选择键盘" msgstr "选择键盘"
#: menu.sh:1007 menu.sh:1017 menu.sh:1022 menu.sh:1028 menu.sh:1032 #: menu.sh:1015 menu.sh:1025 menu.sh:1030 menu.sh:1036 menu.sh:1040
#: menu.sh:1037 menu.sh:1043 menu.sh:1050 menu.sh:1054 menu.sh:1071 #: menu.sh:1045 menu.sh:1051 menu.sh:1058 menu.sh:1062 menu.sh:1079
msgid "Update arpl" msgid "Update arpl"
msgstr "更新arpl" msgstr "更新arpl"
#: menu.sh:1008 menu.sh:1079 menu.sh:1083 menu.sh:1087 menu.sh:1091 #: menu.sh:1016 menu.sh:1087 menu.sh:1091 menu.sh:1095 menu.sh:1099
#: menu.sh:1095 menu.sh:1100 menu.sh:1110 #: menu.sh:1103 menu.sh:1108 menu.sh:1118
msgid "Update addons" msgid "Update addons"
msgstr "更新插件" msgstr "更新插件"
#: menu.sh:1009 menu.sh:1115 menu.sh:1119 menu.sh:1123 menu.sh:1127 #: menu.sh:1017 menu.sh:1123 menu.sh:1127 menu.sh:1131 menu.sh:1135
#: menu.sh:1131 menu.sh:1136 #: menu.sh:1139 menu.sh:1144
msgid "Update LKMs" msgid "Update LKMs"
msgstr "更新LKMs" msgstr "更新LKMs"
#: menu.sh:1010 #: menu.sh:1018
msgid "Update modules" msgid "Update modules"
msgstr "更新模块" msgstr "更新模块"
#: menu.sh:1011 #: menu.sh:1019
msgid "Set proxy server" msgid "Set proxy server"
msgstr "设置代理" msgstr "设置代理"
#: menu.sh:1018 menu.sh:1080 menu.sh:1116 menu.sh:1153 #: menu.sh:1026 menu.sh:1088 menu.sh:1124 menu.sh:1149
msgid "Checking last version" msgid "Checking last version"
msgstr "检测新版本中" msgstr "检测新版本中"
#: menu.sh:1023 menu.sh:1084 menu.sh:1120 menu.sh:1157 #: menu.sh:1031 menu.sh:1092 menu.sh:1128 menu.sh:1153
msgid "Error checking new version" msgid "Error checking new version"
msgstr "检测新版本错误" msgstr "检测新版本错误"
#: menu.sh:1029 #: menu.sh:1037
msgid "No new version. Actual version is %s\\nForce update?" msgid "No new version. Actual version is %s\\nForce update?"
msgstr "没有新版本. 实际版本为 %s\\n强制更新?" msgstr "没有新版本. 实际版本为 %s\\n强制更新?"
#: menu.sh:1033 #: menu.sh:1041
msgid "Downloading last version %s" msgid "Downloading last version %s"
msgstr "下载新版本 %s 中" msgstr "下载新版本 %s 中"
#: menu.sh:1038 #: menu.sh:1046
msgid "Error downloading update file" msgid "Error downloading update file"
msgstr "下载新版本错误" msgstr "下载新版本错误"
#: menu.sh:1044 #: menu.sh:1052
msgid "Error extracting update file" msgid "Error extracting update file"
msgstr "更新文件解压错误" msgstr "更新文件解压错误"
#: menu.sh:1051 #: menu.sh:1059
msgid "Checksum do not match!" msgid "Checksum do not match!"
msgstr "Checksum不匹配!" msgstr "Checksum不匹配!"
#: menu.sh:1055 #: menu.sh:1063
msgid "Installing new files" msgid "Installing new files"
msgstr "安装更新中" msgstr "安装更新中"
#: menu.sh:1072 #: menu.sh:1080
msgid "Arpl updated with success to %s!\\nReboot?" msgid "Arpl updated with success to %s!\\nReboot?"
msgstr "Arpl更新成功 %s!\\n重启?" msgstr "Arpl更新成功 %s!\\n重启?"
#: menu.sh:1088 menu.sh:1124 #: menu.sh:1096 menu.sh:1132 menu.sh:1158
msgid "Downloading last version" msgid "Downloading last version"
msgstr "下载新版本中" msgstr "下载新版本中"
#: menu.sh:1092 #: menu.sh:1100
msgid "Error downloading new version" msgid "Error downloading new version"
msgstr "下载新版本错误" msgstr "下载新版本错误"
#: menu.sh:1096 menu.sh:1132 #: menu.sh:1104 menu.sh:1140
msgid "Extracting last version" msgid "Extracting last version"
msgstr "解压新版本" msgstr "解压新版本"
#: menu.sh:1101 #: menu.sh:1109
msgid "Installing new addons" msgid "Installing new addons"
msgstr "安装新插件中" msgstr "安装新插件中"
#: menu.sh:1111 #: menu.sh:1119
msgid "Addons updated with success!" msgid "Addons updated with success!"
msgstr "插件更新成功!" msgstr "插件更新成功!"
#: menu.sh:1128 #: menu.sh:1136 menu.sh:1162
msgid "Error downloading last version" msgid "Error downloading last version"
msgstr "下载新版本错误" msgstr "下载新版本错误"
#: menu.sh:1137 #: menu.sh:1145
msgid "LKMs updated with success!" msgid "LKMs updated with success!"
msgstr "LKMs更新成功!" msgstr "LKMs更新成功!"
#: menu.sh:1152 menu.sh:1156 menu.sh:1161 menu.sh:1165 menu.sh:1180 #: menu.sh:1148 menu.sh:1152 menu.sh:1157 menu.sh:1161 menu.sh:1176
msgid "Update Modules" msgid "Update Modules"
msgstr "更新模块" msgstr "更新模块"
#: menu.sh:1162 #: menu.sh:1177
msgid "Downloading %s modules"
msgstr "下载 %s 模块中"
#: menu.sh:1166
msgid "Error downloading %s.tgz"
msgstr "下载 %s.tgz 错误"
#: menu.sh:1181
msgid "Modules updated with success!" msgid "Modules updated with success!"
msgstr "模块更新成功!" msgstr "模块更新成功!"
#: menu.sh:1186 #: menu.sh:1182
msgid "Set Proxy Server" msgid "Set Proxy Server"
msgstr "设置代理" msgstr "设置代理"
#: menu.sh:1187 #: menu.sh:1183
msgid "Please enter a proxy server url" msgid "Please enter a proxy server url"
msgstr "请输入代理服务器url" msgstr "请输入代理服务器url"
#: menu.sh:1198 #: menu.sh:1194
msgid "Invalid proxy server url, continue?" msgid "Invalid proxy server url, continue?"
msgstr "无效的代理服务器url,是否继续?" msgstr "无效的代理服务器url,是否继续?"
#: menu.sh:1221 #: menu.sh:1217
msgid "Choose a model" msgid "Choose a model"
msgstr "选择型号" msgstr "选择型号"
#: menu.sh:1223 #: menu.sh:1219
msgid "Choose a Build Number" msgid "Choose a Build Number"
msgstr "选择版本" msgstr "选择版本"
#: menu.sh:1224 #: menu.sh:1220
msgid "Choose a serial number" msgid "Choose a serial number"
msgstr "选择SN" msgstr "选择SN"
#: menu.sh:1226 #: menu.sh:1222
msgid "Addons" msgid "Addons"
msgstr "插件" msgstr "插件"
#: menu.sh:1227 #: menu.sh:1223
msgid "Cmdline menu" msgid "Cmdline menu"
msgstr "设置Cmdline" msgstr "设置Cmdline"
#: menu.sh:1228 #: menu.sh:1224
msgid "Synoinfo menu" msgid "Synoinfo menu"
msgstr "设置Synoinfo" msgstr "设置Synoinfo"
#: menu.sh:1231 #: menu.sh:1227
msgid "Advanced menu" msgid "Advanced menu"
msgstr "高级设置" msgstr "高级设置"
#: menu.sh:1234 #: menu.sh:1230
msgid "Build the loader" msgid "Build the loader"
msgstr "编译引导" msgstr "编译引导"
#: menu.sh:1238 #: menu.sh:1234
msgid "Boot the loader" msgid "Boot the loader"
msgstr "启动" msgstr "启动"
#: menu.sh:1241 #: menu.sh:1237
msgid "Choose a keymap" msgid "Choose a keymap"
msgstr "选择键盘" msgstr "选择键盘"
#: menu.sh:1243 #: menu.sh:1239
msgid "Clean disk cache" msgid "Clean disk cache"
msgstr "清除磁盘缓存" msgstr "清除磁盘缓存"
#: menu.sh:1245 #: menu.sh:1241
msgid "Update menu" msgid "Update menu"
msgstr "更新" msgstr "更新"
#: menu.sh:1271 #: menu.sh:1267
msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu"
msgstr "执行 \\033[1;32mmenu.sh\\033[0m 重新进入设置菜单" msgstr "执行 \\033[1;32mmenu.sh\\033[0m 重新进入设置菜单"

View File

@ -392,31 +392,34 @@ function cmdlineMenu() {
done done
;; ;;
c) c)
NUM=`ip link show | grep ether | wc -l`
for i in $(seq 1 ${NUM}); do
RET=1 RET=1
while true; do while true; do
dialog --backtitle "`backtitle`" --title "$(TEXT "User cmdline")" \ dialog --backtitle "`backtitle`" --title "$(TEXT "User cmdline")" \
--inputbox "$(TEXT "Type a custom MAC address")" 0 0 "${CMDLINE['mac1']}"\ --inputbox "`printf "$(TEXT "Type a custom MAC address of %s")" "eth$(expr ${i} - 1)"`" 0 0 "${CMDLINE["mac${i}"]}"\
2>${TMP_PATH}/resp 2>${TMP_PATH}/resp
RET=$? RET=$?
[ ${RET} -ne 0 ] && break [ ${RET} -ne 0 ] && break
MAC="`<"${TMP_PATH}/resp"`" MAC="`<"${TMP_PATH}/resp"`"
[ -z "${MAC}" ] && MAC="`readConfigKey "original-mac" "${USER_CONFIG_FILE}"`" [ -z "${MAC}" ] && MAC="`readConfigKey "original-mac${i}" "${USER_CONFIG_FILE}"`"
MAC1="`echo "${MAC}" | sed 's/://g'`" MACF="`echo "${MAC}" | sed 's/://g'`"
[ ${#MAC1} -eq 12 ] && break [ ${#MACF} -eq 12 ] && break
dialog --backtitle "`backtitle`" --title "$(TEXT "User cmdline")" --msgbox "$(TEXT "Invalid MAC")" 0 0 dialog --backtitle "`backtitle`" --title "$(TEXT "User cmdline")" --msgbox "$(TEXT "Invalid MAC")" 0 0
done done
if [ ${RET} -eq 0 ]; then if [ ${RET} -eq 0 ]; then
CMDLINE["mac1"]="${MAC1}" CMDLINE["mac${i}"]="${MACF}"
CMDLINE["netif_num"]=1 CMDLINE["netif_num"]=${NUM}
writeConfigKey "cmdline.mac1" "${MAC1}" "${USER_CONFIG_FILE}" writeConfigKey "cmdline.mac${i}" "${MACF}" "${USER_CONFIG_FILE}"
writeConfigKey "cmdline.netif_num" "1" "${USER_CONFIG_FILE}" writeConfigKey "cmdline.netif_num" "${NUM}" "${USER_CONFIG_FILE}"
MAC="${MAC1:0:2}:${MAC1:2:2}:${MAC1:4:2}:${MAC1:6:2}:${MAC1:8:2}:${MAC1:10:2}" MAC="${MACF:0:2}:${MACF:2:2}:${MACF:4:2}:${MACF:6:2}:${MACF:8:2}:${MACF:10:2}"
ip link set dev eth0 address ${MAC} 2>&1 | dialog --backtitle "`backtitle`" \ ip link set dev eth$(expr ${i} - 1) address ${MAC} 2>&1 | dialog --backtitle "`backtitle`" \
--title "$(TEXT "User cmdline")" --progressbox "$(TEXT "Changing MAC")" 20 70 --title "$(TEXT "User cmdline")" --progressbox "$(TEXT "Changing MAC")" 20 70
/etc/init.d/S41dhcpcd restart 2>&1 | dialog --backtitle "`backtitle`" \ /etc/init.d/S41dhcpcd restart 2>&1 | dialog --backtitle "`backtitle`" \
--title "$(TEXT "User cmdline")" --progressbox "$(TEXT "Renewing IP")" 20 70 --title "$(TEXT "User cmdline")" --progressbox "$(TEXT "Renewing IP")" 20 70
IP=`ip route get 1.1.1.1 2>/dev/null | awk '{print$7}'` IP=`ip route 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p' | head -1` # IP=`ip route get 1.1.1.1 2>/dev/null | awk '{print$7}'`
fi fi
done
;; ;;
s) s)
ITEMS="" ITEMS=""
@ -768,6 +771,8 @@ function advancedMenu() {
t) tryRecoveryDSM ;; t) tryRecoveryDSM ;;
s) MSG="" s) MSG=""
NUMPORTS=0 NUMPORTS=0
ATTACHTPORTS=0
DiskIdxMap=""
for PCI in `lspci -d ::106 | awk '{print$1}'`; do for PCI in `lspci -d ::106 | awk '{print$1}'`; do
NAME=`lspci -s "${PCI}" | sed "s/\ .*://"` NAME=`lspci -s "${PCI}" | sed "s/\ .*://"`
MSG+="\Zb${NAME}\Zn\nPorts: " MSG+="\Zb${NAME}\Zn\nPorts: "
@ -782,15 +787,18 @@ function advancedMenu() {
ls -l /sys/block | fgrep -q "${PCI}/ata${PORT}" && ATTACH=1 || ATTACH=0 ls -l /sys/block | fgrep -q "${PCI}/ata${PORT}" && ATTACH=1 || ATTACH=0
PCMD=`cat /sys/class/scsi_host/${HOSTPORTS[${PORT}]}/ahci_port_cmd` PCMD=`cat /sys/class/scsi_host/${HOSTPORTS[${PORT}]}/ahci_port_cmd`
[ "${PCMD}" = "0" ] && DUMMY=1 || DUMMY=0 [ "${PCMD}" = "0" ] && DUMMY=1 || DUMMY=0
[ ${ATTACH} -eq 1 ] && MSG+="\Z2\Zb" [ ${ATTACH} -eq 1 ] && MSG+="\Z2\Zb" && ATTACHTPORTS=$((${ATTACHTPORTS}+1))
[ ${DUMMY} -eq 1 ] && MSG+="\Z1" [ ${DUMMY} -eq 1 ] && MSG+="\Z1"
MSG+="${PORT}\Zn " MSG+="${PORT}\Zn "
NUMPORTS=$((${NUMPORTS}+1)) NUMPORTS=$((${NUMPORTS}+1))
done < <(echo ${!HOSTPORTS[@]} | tr ' ' '\n' | sort -n) done < <(echo ${!HOSTPORTS[@]} | tr ' ' '\n' | sort -n)
MSG+="\n" MSG+="\n"
DiskIdxMap+=`printf '%02x' ${ATTACHTPORTS}`
done done
MSG+="`printf "$(TEXT "\nTotal of ports: %s\n")" "${NUMPORTS}"`" MSG+="`printf "$(TEXT "\nTotal of ports: %s\n")" "${NUMPORTS}"`"
MSG+="$(TEXT "\nPorts with color \Z1red\Zn as DUMMY, color \Z2\Zbgreen\Zn has drive connected.")" MSG+="$(TEXT "\nPorts with color \Z1red\Zn as DUMMY, color \Z2\Zbgreen\Zn has drive connected.")"
MSG+="$(TEXT "\nRecommended value:")"
MSG+="$(TEXT "\nDiskIdxMap:") ${DiskIdxMap}"
dialog --backtitle "`backtitle`" --colors --aspect 18 \ dialog --backtitle "`backtitle`" --colors --aspect 18 \
--msgbox "${MSG}" 0 0 --msgbox "${MSG}" 0 0
;; ;;