]> git.wh0rd.org Git - home.git/commitdiff
custom-chroot: do not init /root if a git repo is there
authorMike Frysinger <vapier@gentoo.org>
Tue, 25 Aug 2015 17:22:38 +0000 (10:22 -0700)
committerMike Frysinger <vapier@gentoo.org>
Tue, 25 Aug 2015 17:22:38 +0000 (10:22 -0700)
.bin/custom-chroot

index f86e41df71e3f548edb7eda593250d35f711d7a4..13ad020a3a054785b3062ad03d99dc9f04495e73 100755 (executable)
@@ -72,9 +72,11 @@ init_chroot() {
                fi
        done
 
-       f="${HOME}/.profile.d/aliases.sh"
-       if [[ -e ${f} ]] ; then
-               cat "${f}" > root/.bash_profile
+       if [[ ! -d root/.git ]] ; then
+               f="${HOME}/.profile.d/aliases.sh"
+               if [[ -e ${f} ]] ; then
+                       cat "${f}" > root/.bash_profile
+               fi
        fi
 }