Add 'dots/' from commit '357b97a7692c8d5ec9666d8d7d7c98d81cb51cf0'

git-subtree-dir: dots
git-subtree-mainline: 2ad98cde17
git-subtree-split: 357b97a769
This commit is contained in:
2025-10-04 18:28:04 +02:00
232 changed files with 11175 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
# shellcheck shell=bash
# vim: set ft=bash :
reboot-to-windows ()
{
# Check if grub is installed by checking if the command exists, if it does
# not, then assume that the system is using systemd-boot
if grub-install --version &>/dev/null; then
windows_title=$(grep -i windows /boot/grub/grub.cfg | cut -d "'" -f 2)
sudo grub-reboot "$windows_title"
echo "Grub set to reboot to Windows"
else
sudo bootctl set-oneshot windows.conf
echo "Systemd set to reboot to Windows"
fi
}