From: Mike Frysinger Date: Wed, 26 Dec 2012 19:04:34 +0000 (-0500) Subject: mount /usr/local/src if it exists X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=d4759d73bebdc4b4e0883fa78fb86c4653a596f6;p=home.git mount /usr/local/src if it exists --- diff --git a/.bin/custom-chroot b/.bin/custom-chroot index dcaeabc..878a8ff 100755 --- a/.bin/custom-chroot +++ b/.bin/custom-chroot @@ -12,7 +12,7 @@ else fi unset UNSHARE -mounts="proc sys tmp dev dev/pts usr/portage usr/portage/distfiles" +mounts="proc sys tmp dev dev/pts usr/portage usr/portage/distfiles usr/local/src" chroot=${0%/*} case ${chroot} in @@ -22,10 +22,10 @@ esac cd "${chroot}" do_umount() { - mounts=$(mount | grep ${chroot} | awk '{print $3}' | tac) + local m mounts=$(mount | grep ${chroot} | awk '{print $3}' | tac) for m in ${mounts} ; do - echo "unmounting $m" - umount $m + echo "unmounting ${m}" + umount "${m}" done if [[ -z ${mounts} ]] ; then echo "nothing mounted in ${chroot}"