mirror of
https://github.com/ericonr/dotfiles.git
synced 2024-04-21 09:12:33 -05:00
14 lines
258 B
Plaintext
14 lines
258 B
Plaintext
|
#!/bin/sh
|
||
|
|
||
|
# use with sudo -E
|
||
|
|
||
|
ROOTDIR="${1:-/mnt}"
|
||
|
USERNAME="${SUDO_USER:-ericonr}"
|
||
|
|
||
|
chroot "$ROOTDIR" /bin/sudo -u $USERNAME \
|
||
|
env CHROOTED=1 \
|
||
|
XDG_RUNTIME_DIR=$XDG_RUNTIME_DIR \
|
||
|
WAYLAND_DISPLAY=$WAYLAND_DISPLAY \
|
||
|
DISPLAY=$DISPLAY \
|
||
|
/bin/fish -C "cd"
|