core: 修复 efi 条目 inactive 时 (没有*符号) 报错
Some checks failed
运行主程序 / 运行主程序 (./reinstall.bat --debug --password 123@@@, windows-latest) (push) Has been cancelled
运行主程序 / 运行主程序 (sudo bash reinstall.sh --debug --password 123@@@, ubuntu-latest) (push) Has been cancelled
同步到 Gitlab / 同步到 Gitlab (push) Has been cancelled
同步到 Gitlab CN / 同步到 Gitlab CN (push) Has been cancelled

https://manpages.debian.org/unstable/efibootmgr/efibootmgr.8.en.html#Displaying_the_current_settings_(must_be_root):
This commit is contained in:
bin456789 2025-03-23 10:15:48 +08:00
parent 0da940b2a7
commit dd1b3abbfd
No known key found for this signature in database
GPG Key ID: EE301B386DE6C11B
2 changed files with 3 additions and 1 deletions

View File

@ -2588,6 +2588,7 @@ grep_efi_entry() {
grep -E '^Boot[0-9a-fA-F]{4}'
}
# trans.sh 有同名方法
grep_efi_index() {
awk '{print $1}' | sed -e 's/Boot//' -e 's/\*//'
}

View File

@ -822,8 +822,9 @@ del_invalid_efi_entry() {
done < <(efibootmgr | grep 'HD(.*,GPT,')
}
# reinstall.sh 有同名方法
grep_efi_index() {
awk -F '*' '{print $1}' | sed 's/Boot//'
awk '{print $1}' | sed -e 's/Boot//' -e 's/\*//'
}
# 某些机器可能不会回落到 bootx64.efi