From: Ulrich Dangel Date: Mon, 19 Dec 2011 14:21:15 +0000 (+0100) Subject: Add basic grml theme to grub X-Git-Tag: v0.17.1~19 X-Git-Url: http://git.grml.org/?p=grml-live.git;a=commitdiff_plain;h=d501c11085b6c048bf9f4bd186f5ac8d267b9ff6 Add basic grml theme to grub --- diff --git a/grml-live b/grml-live index 3bcf349..020e483 100755 --- a/grml-live +++ b/grml-live @@ -883,7 +883,7 @@ if [ "$ARCH" = i386 ] || [ "$ARCH" = amd64 ] ; then if ! [ -d "${BUILD_OUTPUT}/boot/grub" ] ; then mkdir -p "${BUILD_OUTPUT}/boot/grub" fi - cp ${TEMPLATE_DIRECTORY}/boot/grub/* "$BUILD_OUTPUT"/boot/grub/ + cp -a ${TEMPLATE_DIRECTORY}/boot/grub/* "$BUILD_OUTPUT"/boot/grub/ # copy grub files from target cp -a "${CHROOT_OUTPUT}"/usr/lib/grub/*-pc/*.mod "${BUILD_OUTPUT}"/boot/grub/ diff --git a/templates/boot/grub/grml-theme/grml-logo.png b/templates/boot/grub/grml-theme/grml-logo.png new file mode 100644 index 0000000..bb82fc8 Binary files /dev/null and b/templates/boot/grub/grml-theme/grml-logo.png differ diff --git a/templates/boot/grub/grml-theme/theme.txt b/templates/boot/grub/grml-theme/theme.txt new file mode 100644 index 0000000..bf867ef --- /dev/null +++ b/templates/boot/grub/grml-theme/theme.txt @@ -0,0 +1,44 @@ +title-text: "" +title-color: "#FFFFFF" +desktop-color: "black" +message-color: "#FFFFFF" + ++ image { + file = "grml-logo.png" + left = 45% + top = 2% +} ++ boot_menu { + left = 15% + width = 70% + top = 16% + height = 36% + item_color = "#FFFFFF" + selected_item_color = "orange" + item_spacing = 4 + item_height = 12 + border_color = "#FFFFFF" + +} + + +# Show an informational message. ++ vbox { + top = 55% + left = 20% + + label {text = "Press ENTER to boot or E to edit menu entry " color = "white" align = "left"} + + label {text = "Press C to enter the Grub commandline" color = "white"} +} + ++ progress_bar +{ + id = "__timeout__" + top = 75% + left = 20% + text_color = "#FFFFFF" + fg_color = "orange" + bg_color = #66B + border_color = #006 + text = "@TIMEOUT_NOTIFICATION_LONG@" + +} diff --git a/templates/boot/grub/grub.cfg b/templates/boot/grub/grub.cfg index 71f7e31..ab2f64c 100644 --- a/templates/boot/grub/grub.cfg +++ b/templates/boot/grub/grub.cfg @@ -10,7 +10,9 @@ if loadfont /boot/grub/ascii.pf2 ; then terminal_output gfxterm fi -if background_image /boot/grub/grml.png ; then +if [ -f /boot/grub/grml-theme/theme.txt ] ; then + set theme=/boot/grub/grml-theme/theme.txt +elif background_image /boot/grub/grml.png ; then set color_normal=white/black set color_highlight=red/black set menu_color_normal=white/black @@ -24,6 +26,7 @@ if [ ${iso_path} ] ; then set loopback="findiso=${iso_path}" fi + for config in /boot/grub/*_default.cfg ; do source "$config" ; done for config in /boot/grub/*_options.cfg ; do source "$config" ; done source /boot/grub/addons.cfg