Set the boot splash to blob_boot.png during install
This commit is contained in:
1 parent
d8df9fa320
commit
3fea28e225
7 files changed
+59
-15
No files matched your search
@@ -0,0 +1,37 @@
|
||||
boot_splash_image="$repo_dir/branding/blob_boot.png"
|
||||
boot_splash_theme_dir="/usr/share/plymouth/themes/blob"
|
||||
|
||||
boot_splash_installed() {
|
||||
command -v plymouth-set-default-theme &>/dev/null || return 1
|
||||
[[ -f $boot_splash_theme_dir/blob.plymouth ]] || return 1
|
||||
[[ "$(plymouth-set-default-theme 2>/dev/null)" == blob ]]
|
||||
}
|
||||
|
||||
install_boot_splash() {
|
||||
if ! command -v plymouth-set-default-theme &>/dev/null; then
|
||||
say "SKIP boot splash (plymouth not installed)"
|
||||
return 0
|
||||
fi
|
||||
|
||||
if [[ ! -f $boot_splash_image ]]; then
|
||||
say "SKIP boot splash (branding/blob_boot.png missing)"
|
||||
return 0
|
||||
fi
|
||||
|
||||
if boot_splash_installed && cmp -s "$boot_splash_image" "$boot_splash_theme_dir/logo.png"; then
|
||||
say "ok boot splash"
|
||||
return 0
|
||||
fi
|
||||
|
||||
note_change
|
||||
if [[ $check == true ]]; then
|
||||
say "would set the boot splash to branding/blob_boot.png and rebuild the initramfs"
|
||||
return 0
|
||||
fi
|
||||
|
||||
if BLOB_PATH="$blob_path" "$repo_dir/bin/blob-boot" "$boot_splash_image"; then
|
||||
say "set boot splash to branding/blob_boot.png"
|
||||
else
|
||||
say "WARN could not set the boot splash; run 'blob boot' to retry"
|
||||
fi
|
||||
}
|
||||
@@ -12,10 +12,10 @@ system_services=(
|
||||
# network-online.target must not hold up graphical.target waiting for DHCP or
|
||||
# Wi-Fi association. Nothing in the session blocks on the network.
|
||||
#
|
||||
# Blob configures no boot splash: no mkinitcpio hook, no kernel command line,
|
||||
# and no theme. An unconfigured plymouth still takes the console at boot and
|
||||
# never hands it back, and getty@tty1 waits on plymouth-quit-wait.service, so
|
||||
# the machine comes up with no greeter and no TTY to fix it from.
|
||||
# An unconfigured plymouth takes the console at boot and never hands it back,
|
||||
# and getty@tty1 waits on plymouth-quit-wait.service, so the machine comes up
|
||||
# with no greeter and no TTY to fix it from. The plymouth units are masked
|
||||
# until install_boot_splash configures the blob theme, and left alone after.
|
||||
masked_services=(
|
||||
NetworkManager-wait-online.service
|
||||
plymouth-start.service
|
||||
@@ -64,6 +64,7 @@ mask_system_services() {
|
||||
|
||||
for unit in "${masked_services[@]}"; do
|
||||
system_unit_exists "$unit" || continue
|
||||
[[ $unit == plymouth-* ]] && boot_splash_installed && continue
|
||||
[[ "$(system_unit_state "$unit")" == masked ]] && continue
|
||||
pending+=("$unit")
|
||||
done
|
||||
|
||||
Reference in new issue
Block a user