localboot.cfg 1.29 KB
Newer Older
longpanda's avatar
longpanda committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57

if [ "$grub_platform" = "pc" ]; then
    menuentry 'Search and boot Windows' {    
        if search -n -s -f /bootmgr; then
            ntldr /bootmgr
        elif search -n -s -f /ntldr; then
            ntldr /ntldr
        else
            echo "Windows NOT found ..."
        fi        
    }
    
    menuentry 'Boot the 1st local disk' {
        set root=(hd0,1)
        chainloader +1
        boot
    }
    
    menuentry 'Boot the 2nd local disk' {
        set root=(hd1,1)
        chainloader +1
        boot
    }
    
    menuentry 'Boot the 3rd local disk' {
        set root=(hd2,1)
        chainloader +1
        boot
    }
    
else

    menuentry 'Search and boot Windows' {    
        if search -n -s -f /EFI/Microsoft/Boot/bootmgfw.efi; then
            terminal_output  console
            chainloader /EFI/Microsoft/Boot/bootmgfw.efi
            boot
        else
            echo "Windows NOT found ..."
        fi        
    }
    
    menuentry 'Search and boot BOOTX64.EFI' {    
        if search -n -s -f /efi/boot/bootx64.efi; then
            terminal_output  console
            chainloader /efi/boot/bootx64.efi
            boot
        else
            echo "BOOTX64.EFI NOT found ..."
        fi        
    }

fi

menuentry 'Return to menu [Esc]' VTOY_RET {
    echo 'Return ...'
}