Skip to content

Instantly share code, notes, and snippets.

@PierreZ
Last active August 26, 2018 19:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PierreZ/436d679982552a9e361e71a4c70b6b49 to your computer and use it in GitHub Desktop.
Save PierreZ/436d679982552a9e361e71a4c70b6b49 to your computer and use it in GitHub Desktop.
#!/bin/bash
mkdir /mnt/exherbo && mount /dev/nvme0n1p2 /mnt/exherbo && cd /mnt/exherbo
mount -o rbind /dev /mnt/exherbo/dev/
mount -o bind /sys /mnt/exherbo/sys/
mount -t proc none /mnt/exherbo/proc/
mount /dev/nvme0n1p1 /mnt/exherbo/boot/
env -i TERM=$TERM SHELL=/bin/bash HOME=$HOME $(which chroot) /mnt/exherbo /bin/bash
source /etc/profile
export PS1="(chroot) $PS1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment