Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

77 fix initial setup installation #78

Merged
merged 3 commits into from
Nov 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion elements/components/initial-setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ merge: [version.yml]
about: System Initial Setup

variables:
commit: e67c8c3d91cd7f1d8165f596fd1abdf3eb35d0f4
commit: f1dae25a548e32a9b309042ed57baeccc9360531
release: 1

post-script: |-
Expand Down
78 changes: 77 additions & 1 deletion files/initial-setup/installer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,83 @@ fi
sudo sed -i 's#linux /ostree#linux /boot/ostree#g' ${SYSROOT}/boot/loader/grub.cfg
sudo sed -i 's#initrd /ostree#initrd /boot/ostree#g' ${SYSROOT}/boot/loader/grub.cfg

sudo install -D -m 0644 /dev/stdin ${SYSROOT}/boot/grub/grub.cfg << EOF
sudo install -D -m 0644 /dev/stdin ${SYSROOT}/boot/grub/grub.cfg << "EOF"
set timeout=5
if [ -s $prefix/grubenv ] ; then
set have_grubenv=true
load_env
fi

if [ x"${feature_menuentry_id}" = xy ] ; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ] ; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set pre_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z "${boot_once}" ] ; then
saved_entry="${chosed}"
save_env saved_entry
fi
}

function load_video {
if [ x$feature_all_video_module = xy ] ; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}

font=unicode

if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_US
insmod gettext
fi

terminal_output gfxterm
if [ "${recordfail}" = 1 ] ; then
set timeout=30
else
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
else
set timeout=5
fi
fi

function gfxmode {
set gfxpayload="${1}"
}

set linux_gfx_mode=
export linux_gfx_mode

insmod part_gpt
insmod ext2

configfile /boot/loader/grub.cfg
EOF

Expand Down
Loading