working on solving unfortunate sub-link traversals
authorFred T. Hamster <fred@feistymeow.org>
Fri, 13 Feb 2026 01:22:00 +0000 (20:22 -0500)
committerFred T. Hamster <fred@feistymeow.org>
Fri, 13 Feb 2026 01:22:00 +0000 (20:22 -0500)
the rcheckin command will go into sub-folders in the directory that are links, which we would prefer it not do.
there are cases where the linked sub-folder is a software product we do not have rights to update, so we should not be
trying to dive into there and mess with the source.
if a linked sub-folder does need to be checked in, then that is a special case that will have to be dealt with
somewhere else, currently.

scripts/rev_control/version_control.sh

index 90761484a56edca5f22091041bf4868b8774993c..2396dc3f97f7f7e94ce3358f49024f3268aedb03 100644 (file)
@@ -551,6 +551,8 @@ function puff_out_list()
 # that are located under the directory passed as the first parameter.
 # if this does not result in any directories being found, then a recursive
 # upwards search is done for git repos, which wants the .git directory.
+# note that this will skip links, unless the directory passed is itself a
+# link; it will be entered, but links underneath it will be ignored.
 function generate_rev_ctrl_filelist()
 {
   local dir="$1"; shift
@@ -559,14 +561,19 @@ function generate_rev_ctrl_filelist()
   local tempfile=$(mktemp /tmp/zz_checkins.XXXXXX)
   echo -n >$tempfile
   local additional_filter
-  find $dirhere -follow -maxdepth $MAX_DEPTH -type d -iname ".svn" -exec echo {}/.. ';' >>$tempfile 2>/dev/null
+  # we will still enter into dirhere if it's a link, but we will not follow into sub-links.
+  find $dirhere/. -maxdepth $MAX_DEPTH -type d -iname ".svn" -exec echo {}/.. ';' >>$tempfile 2>/dev/null
+#-follow 
 
 #hmmm: how to get the report of things ABOVE here, which we need.
 #  can we do an exec using the seek writable?
 
-  find $dirhere -follow -maxdepth $MAX_DEPTH -type d -iname ".git" -exec echo {}/.. ';' >>$tempfile 2>/dev/null
+  # we will still enter into dirhere if it's a link, but we will not follow into sub-links.
+  find $dirhere/. -maxdepth $MAX_DEPTH -type d -iname ".git" -exec echo {}/.. ';' >>$tempfile 2>/dev/null
+#-follow 
 
   # CVS is not well behaved like git and (now) svn, and we seldom use it anymore.
+
   popd &>/dev/null
 
   # see if they've warned us not to try checking in within vendor hierarchies.