-locks_present()
-{
- # git-cvsimport by default skips commits that are not at least 10 minutes
- # old to try to prevent importing partial commits. However, because
- # rsync may take a long time to run, this doesn't really work. So we look
- # for lock files and don't sync if they exist.
- #
- # For the sf.net tinyos repo, lock files are created with a permissions
- # level that prevents them from being read by the remote rsync, causing
- # rsync to error. For the current configuration of the upstream CVS in
- # this case, we never really get to test the mettle of this function.
-
- lines=$(find . -name "#cvs*" | wc -l)
- if [ $lines -gt 0 ]; then
- return 0 # locks are present
- else
- return 1 # no locks present
- fi
-}
-