[Boot/Shutdown] 关于bootmgr能否美化一下啊
Tofloor
poster avatar
daveluoster
deepin
2023-12-09 20:09
Author

因为工作原因,需要安装deepin和win双系统,默认是deepin的启动管理(自己水平有限,又不会修改默认选择启动系统的界面),这界面……能否使用图片代替无法缩放字体的启动选项啊,差点带近视眼才看得清启动选项……

Reply Favorite View the author
All Replies
neko
deepin
Ecological co-builder
2023-12-09 20:43
#1

是否在寻找grub主题

Reply View the author
nexfia
deepin
2023-12-09 20:52
#2

自己动手,丰衣足食tail

Reply View the author
云的眼泪
deepin
2023-12-09 20:56
#3

下载安装grub主题

或者修改默认主题,有风险

image.png

Reply View the author
忘记、过去
deepin
2023-12-09 22:10
#4

写了个脚本,直接用 sudo 运行,替你修改下 grub 主题吧......

adjust-deepin-grub-theme.tar.gz

#!/bin/bash

# Judge system distributor
DISTRIBUTOR=$(lsb_release -i -s | tr '[A-Z]' '[a-z]')
if [ $DISTRIBUTOR != "deepin" -a $DISTRIBUTOR != "uos" ] ; then
    echo "Only Deepin and UOS can run this script!"
    exit -1
fi

# Judge uid
if [ "$(id -u)" != "0" ] ; then
    echo "Please run this script as root!"
    exit 1
fi

echo "You are trying to adjust your grub theme, please use this script at your own risk."

# Remove cfg created by com.deepin.daemon.Grub2 in UOS 1060
rm -f /etc/default/grub.d/11_dde.cfg

# Create /boot/grub/themes/deepin (if not existed)
if [ ! -d "/boot/grub/themes/deepin" ] ; then
    /usr/lib/deepin-api/adjust-grub-theme > /dev/null 2>&1
fi

# Provide default background_source (if not existed)
if [ ! -f "/boot/grub/themes/deepin/background_source" ] ; then
    cp -f /boot/grub/themes/deepin-fallback/background.jpg /boot/grub/themes/deepin/background_source
fi

# Enter screen resolution
echo -n "Enter your screen resolution (e.g. 1920x1080): "
read RESOLUTION

# Edit /etc/default/grub
sed -i '/^GRUB_BACKGROUND=*/c\GRUB_BACKGROUND="/boot/grub/themes/deepin/background.jpg"' /etc/default/grub
sed -i "/^GRUB_GFXMODE=*/c\GRUB_GFXMODE=\"${RESOLUTION}\"" /etc/default/grub
sed -i '/^GRUB_THEME=*/c\GRUB_THEME="/boot/grub/themes/deepin/theme.txt"' /etc/default/grub

# Update /boot/grub/themes/deepin
/usr/lib/deepin-api/adjust-grub-theme

# Update /boot/grub/grub.cfg
update-grub

echo
echo "Your /etc/default/grub has been changed:"
cat /etc/default/grub

sleep 3

echo
echo "adjust-grub-theme succeeded, press any key to exit..."
read

exit 0
Reply View the author
忘记、过去
deepin
2023-12-09 23:50
#5
It has been deleted!