"backend/apps/webui/internal/migrations/015_add_functions.py" did not exist on "363ab562c3110194fb721591ffe304ba09e6e1b0"
localboot.cfg 6.06 KB
Newer Older
longpanda's avatar
longpanda committed
1
2

if [ "$grub_platform" = "pc" ]; then
3
    menuentry "$VTLANG_LB_SBOOT_WINDOWS" --class=boot_windows --class=F4boot {
longpanda's avatar
longpanda committed
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
    
        set partid=3
        while [ $partid -le 128 ]; do
            if vt_check_part_exist $partid; then
                for bt in bootmgr BOOTMGR Bootmgr BootMGR; do
                    if [ -f ($vtoydev,$partid)/$bt ]; then
                        set root=($vtoydev,$partid)
                        ntldr /$bt
                        boot
                    fi
                done
            else
                break
            fi
            vt_incr partid 1
        done
    
        if search -n -s -f /Boot/BCD; then
            for bt in bootmgr BOOTMGR Bootmgr BootMGR; do
                if [ -f /$bt ]; then
longpanda's avatar
longpanda committed
24
25
26
27
28
29
                    if regexp '^hd0' $root; then
                        ntldr /$bt
                    else
                        drivemap -s hd0 $root
                        ntldr /$bt
                    fi
longpanda's avatar
longpanda committed
30
31
32
33
34
35
                    break
                fi
            done
        elif search -n -s -f /NTDETECT.COM; then
            drivemap -s hd0 $root
            ntldr /ntldr
longpanda's avatar
longpanda committed
36
37
38
39
40
        else
            echo "Windows NOT found ..."
        fi        
    }
    
41
    menuentry "$VTLANG_LB_SBOOT_G4D" --class=boot_g4d --class=F4boot {
longpanda's avatar
longpanda committed
42
43
44
45
46
47
48
        if search -n -s -f /grldr; then
            ntldr /grldr
        else
            echo "Grub4dos NOT found ..."
        fi        
    }
    
49
    menuentry "$VTLANG_LB_SBOOT_HDD1" --class=boot_disk --class=F4boot {
longpanda's avatar
longpanda committed
50
51
52
53
54
        set root=(hd0,1)
        chainloader +1
        boot
    }
    
55
    menuentry "$VTLANG_LB_SBOOT_HDD2" --class=boot_disk --class=F4boot {
longpanda's avatar
longpanda committed
56
57
58
59
60
        set root=(hd1,1)
        chainloader +1
        boot
    }
    
61
    menuentry "$VTLANG_LB_SBOOT_HDD3" --class=boot_disk --class=F4boot {
longpanda's avatar
longpanda committed
62
63
64
65
66
67
68
        set root=(hd2,1)
        chainloader +1
        boot
    }
    
else

69
    menuentry "$VTLANG_LB_SBOOT_WINDOWS" --class=boot_windows --class=F4boot {    
longpanda's avatar
longpanda committed
70
71
72
73
74
75
76
77
78
        
        set partid=3
        while [ $partid -le 128 ]; do
            if vt_check_part_exist $partid; then
                if [ -f ($vtoydev,$partid)/EFI/Microsoft/Boot/bootmgfw.efi ]; then
                    set root=($vtoydev,$partid)
                    terminal_output  console
                    chainloader /EFI/Microsoft/Boot/bootmgfw.efi
                    boot
79
80
81
82
83
                elif [ -f ($vtoydev,$partid)/efi/Microsoft/Boot/bootmgfw.efi ]; then
                    set root=($vtoydev,$partid)
                    terminal_output  console
                    chainloader /efi/Microsoft/Boot/bootmgfw.efi
                    boot
longpanda's avatar
longpanda committed
84
85
86
87
88
89
90
                fi
            else
                break
            fi
            vt_incr partid 1
        done
                
longpanda's avatar
longpanda committed
91
92
93
94
        if search -n -s -f /EFI/Microsoft/Boot/bootmgfw.efi; then
            terminal_output  console
            chainloader /EFI/Microsoft/Boot/bootmgfw.efi
            boot
95
96
97
98
        elif search -n -s -f /efi/Microsoft/Boot/bootmgfw.efi; then
            terminal_output  console
            chainloader /efi/Microsoft/Boot/bootmgfw.efi
            boot
longpanda's avatar
longpanda committed
99
100
101
102
103
        else
            echo "Windows NOT found ..."
        fi        
    }
    
longpanda's avatar
longpanda committed
104
    if [ "$grub_cpu" = "i386" ]; then
105
        menuentry "$VTLANG_LB_SBOOT_IA32EFI" --class=boot_uefi --class=F4boot {
longpanda's avatar
longpanda committed
106
107
108
109
110
111
112
113
114
115
116
            set VTOY_SEARCH_NO_VTOYEFI=1
            if search -n -s -f /efi/boot/bootia32.efi; then
                unset VTOY_SEARCH_NO_VTOYEFI
                terminal_output  console
                chainloader /efi/boot/bootia32.efi
                boot
            else
                unset VTOY_SEARCH_NO_VTOYEFI
                echo "BOOTIA32.EFI NOT found ..."
            fi        
        }
longpanda's avatar
longpanda committed
117
        
118
        menuentry "$VTLANG_LB_SBOOT_XORBOOT" --class=boot_xorboot --class=F4boot {
longpanda's avatar
longpanda committed
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
            set VTOY_SEARCH_NO_VTOYEFI=1
            if search -n -s -f /efi/xorboot/xorboot32.xor; then
                unset VTOY_SEARCH_NO_VTOYEFI
                terminal_output  console
                if [ -f /efi/xorboot/bootia32.efi ]; then
                    chainloader /efi/xorboot/bootia32.efi
                elif [ -f /efi/xorboot/xorboot.efi ]; then
                    chainloader /efi/xorboot/xorboot.efi
                fi
                boot
            else
                unset VTOY_SEARCH_NO_VTOYEFI
                echo "xorboot NOT found ..."
            fi        
        }
longpanda's avatar
longpanda committed
134
    elif [ "$grub_cpu" = "arm64" ]; then
135
        menuentry "$VTLANG_LB_SBOOT_AA64EFI" --class=boot_uefi --class=F4boot {
longpanda's avatar
longpanda committed
136
137
138
139
140
141
142
143
144
145
146
147
            set VTOY_SEARCH_NO_VTOYEFI=1
            if search -n -s -f /efi/boot/bootaa64.efi; then
                unset VTOY_SEARCH_NO_VTOYEFI
                terminal_output  console
                chainloader /efi/boot/bootaa64.efi
                boot
            else
                unset VTOY_SEARCH_NO_VTOYEFI
                echo "BOOTAA64.EFI NOT found ..."
            fi        
        }
    else
148
        menuentry "$VTLANG_LB_SBOOT_X64EFI" --class=boot_uefi --class=F4boot {
longpanda's avatar
longpanda committed
149
150
151
152
153
154
155
156
157
158
159
            set VTOY_SEARCH_NO_VTOYEFI=1
            if search -n -s -f /efi/boot/bootx64.efi; then
                unset VTOY_SEARCH_NO_VTOYEFI
                terminal_output  console
                chainloader /efi/boot/bootx64.efi
                boot
            else
                unset VTOY_SEARCH_NO_VTOYEFI
                echo "BOOTX64.EFI NOT found ..."
            fi        
        }
longpanda's avatar
longpanda committed
160

161
        menuentry "$VTLANG_LB_SBOOT_XORBOOT" --class=boot_xorboot --class=F4boot {
longpanda's avatar
longpanda committed
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
            set VTOY_SEARCH_NO_VTOYEFI=1
            if search -n -s -f /efi/xorboot/xorboot.xor; then
                unset VTOY_SEARCH_NO_VTOYEFI
                terminal_output  console
                if [ -f /efi/xorboot/bootx64.efi ]; then
                    chainloader /efi/xorboot/bootx64.efi
                elif [ -f /efi/xorboot/xorboot.efi ]; then
                    chainloader /efi/xorboot/xorboot.efi
                fi
                boot
            else
                unset VTOY_SEARCH_NO_VTOYEFI
                echo "xorboot NOT found ..."
            fi        
        }
longpanda's avatar
longpanda committed
177
178
    fi
    
longpanda's avatar
longpanda committed
179
180
181

fi

182
183
menuentry "$VTLANG_RETURN_PREVIOUS" --class=vtoyret VTOY_RET {
    echo "Return ..."
longpanda's avatar
longpanda committed
184
}