grub-theme-udt
A GRUB 2 theme for the unified-desktop-theme (udt) family. The background is a snapshot of the current wallpaper; a translucent panel on the left carries the menu, in the active udt scheme's colours.
How it is wired
theme.txt.in is a template. udt's udt-palette renders it to theme.txt
with the scheme's colours, then udt's install.sh runs ./build, which
assembles the complete theme in dist/udt/: theme.txt, the PNG slices in
the same colours, the .pf2 fonts and background.jpg, a GRUB-readable copy
of ~/.cache/udt/wpaper. Both outputs are gitignored.
The panel title is the machine's pretty name, PRETTY_HOSTNAME in
/etc/machine-info, or the OS name from /etc/os-release when that is not
set. udt's udt-machine-name sets it, keeping any other keys in the file:
sudo udt-machine-name "My Machine"
The accent is the scheme's fixed accent role, not the wallpaper-tracking
one: nothing at boot can read that.
Install
GRUB reads /boot before anything else is mounted, so the theme is copied,
not linked. In a root shell:
rm -rf /boot/grub/themes/udt && cp -r <this repo>/dist/udt /boot/grub/themes/
Once, set this in /etc/default/grub:
GRUB_THEME="/boot/grub/themes/udt/theme.txt"
then regenerate the config:
grub-mkconfig -o /boot/grub/grub.cfg
udt's install.sh prints these commands after a successful build; it never
runs them.
After a scheme or wallpaper change
Rerun udt's install.sh, then the cp line above. grub-mkconfig is only
needed when GRUB_THEME changes. The theme on /boot stays as it was until
root copies the new one.
Requirements
GRUB 2.14 or later (for desktop-image-scale-method), Python 3, grub-mkfont,
fc-match, ImageMagick's magick, and the fonts Noto Sans (Regular, Bold)
and Inconsolata Nerd Font Mono.
Test
./build --selftest
./preview # headless, screenshot to dist/preview.png
./preview --live # QEMU window: move through the menu, 'c' for the console
./preview 1920x1080 # another mode
preview boots dist/udt in real GRUB (x86_64-efi) under QEMU and OVMF, with
stand-in menu entries, so the theme can be checked before root installs it.
It needs qemu-system-x86_64, OVMF in /usr/share/OVMF and grub-mkimage.
License
GPLv2 only. See LICENSE.
Development Approach
This project is developed using AI-assisted tools. Code is generated with the help of AI based on human-provided specifications, design decisions, and iterative feedback.
All contributions are reviewed, tested, and curated by the maintainer before being included in the codebase. AI is used as a productivity and exploration tool, while human oversight remains central to all decisions.
The goal is to combine the flexibility of AI-assisted development with standard open-source practices such as transparency, review, and accountability.
