summaryrefslogtreecommitdiff
path: root/bin/repairboot
diff options
context:
space:
mode:
authorMarc Vertes <mvertes@free.fr>2021-02-07 12:03:10 +0100
committerMarc Vertes <mvertes@free.fr>2021-02-07 12:03:10 +0100
commit9aa203f7d7a1899aac7bb7d8209cc2a394ffdbd8 (patch)
treeff1b44cfe5dd5c651347fc8c0bd1eb9b931bd7f9 /bin/repairboot
parent5aaa36fd6bc42d127617e92bd1907816e82bfff0 (diff)
update
Diffstat (limited to 'bin/repairboot')
-rwxr-xr-xbin/repairboot14
1 files changed, 14 insertions, 0 deletions
diff --git a/bin/repairboot b/bin/repairboot
new file mode 100755
index 0000000..6cb9bb4
--- /dev/null
+++ b/bin/repairboot
@@ -0,0 +1,14 @@
+#!/bin/sh -ex
+
+# Repair boot from yoda (for acer swift5)
+
+
+[ "$USER" = root ] || exec sudo "$0" "$@"
+
+cryptsetup open /dev/nvme0n1p2 swift
+mount /dev/mapper/swift /mnt
+mount /dev/nvme0n1p1 /mnt/boot
+
+arch-chroot /mnt << EOT
+bootctl --path=/boot install
+EOT