mirror of
https://github.com/ventoy/Ventoy.git
synced 2025-08-28 00:11:15 +00:00
Show a warning message if ventoy.json is in UCS-2 encoding. (#1125)
ventoy.json must in UTF-8 encoding. The BOM is auto skipped if exist.
This commit is contained in:
@@ -2178,12 +2178,19 @@ fi
|
||||
|
||||
if [ -n "$VTOY_PLUGIN_SYNTAX_ERROR" ]; then
|
||||
clear
|
||||
echo -e "\n Syntax error detected in ventoy.json, please check! \n"
|
||||
echo -e " ventoy.json 文件中有语法错误,所有配置都不会生效,请检查!\n"
|
||||
if [ -n "$VTOY_PLUGIN_ENCODE_ERROR" ]; then
|
||||
echo -e "\n Encoding type for ventoy.json is not supported, please convert to UTF-8.\n"
|
||||
echo -e " ventoy.json 文件编码格式不支持,请转换为 UTF-8 编码格式!\n"
|
||||
else
|
||||
echo -e "\n Syntax error detected in ventoy.json, please check! \n"
|
||||
echo -e " ventoy.json 文件中有语法错误,所有配置都不会生效,请检查!\n"
|
||||
fi
|
||||
|
||||
echo -e "\n press ENTER to continue (请按 回车 键继续) ..."
|
||||
read vtInputKey
|
||||
read vtInputKey
|
||||
fi
|
||||
|
||||
|
||||
for vtTFile in ventoy.json ventoy_grub.cfg; do
|
||||
if [ -f $vtoy_efi_part/ventoy/$vtTFile ]; then
|
||||
clear
|
||||
|
Reference in New Issue
Block a user