comparison .zsh/50.vcs_functions.zsh @ 31:a5691a22c92b

Fix a bug in update_source_trees where it could eat any existing dirstack entries if there were any non-directories in the working directory.
author Augie Fackler <durin42@gmail.com>
date Mon, 05 Jan 2009 11:46:29 -0600
parents 0de17fe9c428
children 7e9269048856
comparison
equal deleted inserted replaced
30:43e751bdedeb 31:a5691a22c92b
38 38
39 # Function to update source trees of known VCS tools in the working dir. 39 # Function to update source trees of known VCS tools in the working dir.
40 # "known" means ones I'm forced to use on a regular basis 40 # "known" means ones I'm forced to use on a regular basis
41 function update_source_trees() { 41 function update_source_trees() {
42 for aa in */ ; do 42 for aa in */ ; do
43 pushd $aa > /dev/null 43 pushd $aa > /dev/null || continue
44 if [ -e .svn ] ; then 44 if [ -e .svn ] ; then
45 echo $aa 'is an svn checkout, updating' 45 echo $aa 'is an svn checkout, updating'
46 svn up 46 svn up
47 elif [ -e .hg/svn ] ; then 47 elif [ -e .hg/svn ] ; then
48 echo $aa 'is an hg-svn checkout, updating' 48 echo $aa 'is an hg-svn checkout, updating'