-
-
Save sleeyax/b651e5113061523a2af47f473840edeb to your computer and use it in GitHub Desktop.
Reinstall grub after Windows updates (Arch & Windows dual boot)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# list partitions | |
lsblk -f | |
# mount the root partition | |
mount /dev/nvme1n1p2 /mnt | |
# mount the boot partition | |
mount /dev/nvme1n1p1 /mnt/boot | |
# change root to root partition on /mnt | |
arch-chroot /mnt | |
# reinstall grub | |
grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB --removable | |
grub-mkconfig -o /boot/grub/grub.cfg | |
# exit partition, unmount and reboot | |
exit | |
umount -R /mnt | |
reboot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment