diff --git a/git-clone.sh b/git-clone.sh index 513b574d13..1cbc2f5858 100755 --- a/git-clone.sh +++ b/git-clone.sh @@ -224,7 +224,7 @@ yes,yes) no) # See if we can hardlink and drop "l" if not. sample_file=$(cd "$repo" && \ - find objects -type f -print | sed -e 1q) + /usr/bin/find objects -type f -print | sed -e 1q) # objects directory should not be empty since we are cloning! test -f "$repo/$sample_file" || exit @@ -236,7 +236,7 @@ yes,yes) fi && rm -f "$GIT_DIR/objects/sample" && cd "$repo" && - find objects -depth -print | cpio -pumd$l "$GIT_DIR/" || exit 1 + /usr/bin/find objects -depth -print | cpio -pumd$l "$GIT_DIR/" || exit 1 ;; yes) mkdir -p "$GIT_DIR/objects/info" @@ -354,7 +354,7 @@ then ( test -f "$GIT_DIR/$remote_top/master" && echo "master" cd "$GIT_DIR/$remote_top" && - find . -type f -print | sed -e 's/^\.\///' + /usr/bin/find . -type f -print | sed -e 's/^\.\///' ) | ( done=f while read name diff --git a/git-ls-remote.sh b/git-ls-remote.sh index a6ed99a7c5..145fc38c79 100755 --- a/git-ls-remote.sh +++ b/git-ls-remote.sh @@ -79,7 +79,7 @@ rsync://* ) head=$(cat "$tmpdir/$head") || exit esac && echo "$head HEAD" - (cd $tmpdir && find refs -type f) | + (cd $tmpdir && /usr/bin/find refs -type f) | while read path do cat "$tmpdir/$path" | tr -d '\012' diff --git a/git-repack.sh b/git-repack.sh index ddfa8b44a1..bf0bdcf4ff 100755 --- a/git-repack.sh +++ b/git-repack.sh @@ -46,7 +46,7 @@ case ",$all_into_one," in ;; ,t,) if [ -d "$PACKDIR" ]; then - for e in `cd "$PACKDIR" && find . -type f -name '*.pack' \ + for e in `cd "$PACKDIR" && /usr/bin/find . -type f -name '*.pack' \ | sed -e 's/^\.\///' -e 's/\.pack$//'` do if [ -e "$PACKDIR/$e.keep" ]; then diff --git a/t/t0000-basic.sh b/t/t0000-basic.sh index 81ec70ff93..66898afc4f 100755 --- a/t/t0000-basic.sh +++ b/t/t0000-basic.sh @@ -50,14 +50,14 @@ test "$no_symlinks" && { # git-init has been done in an empty repository. # make sure it is empty. -find .git/objects -type f -print >should-be-empty +/usr/bin/find .git/objects -type f -print >should-be-empty test_expect_success \ '.git/objects should be empty after git-init in an empty repo.' \ 'cmp -s /dev/null should-be-empty' # also it should have 2 subdirectories; no fan-out anymore, pack, and info. # 3 is counting "objects" itself -find .git/objects -type d -print >full-of-directories +/usr/bin/find .git/objects -type d -print >full-of-directories test_expect_success \ '.git/objects should have 3 subdirectories.' \ 'test $(wc -l < full-of-directories) = 3' @@ -112,7 +112,7 @@ do done test_expect_success \ 'adding various types of objects with git-update-index --add.' \ - 'find path* ! -type d -print | xargs git-update-index --add' + '/usr/bin/find path* ! -type d -print | xargs git-update-index --add' # Show them and see that matches what we expect. test_expect_success \ diff --git a/t/t1200-tutorial.sh b/t/t1200-tutorial.sh index ca2c30f7af..97bf4dc517 100755 --- a/t/t1200-tutorial.sh +++ b/t/t1200-tutorial.sh @@ -156,7 +156,7 @@ test_expect_success 'git show-branch' 'cmp show-branch2.expect show-branch2.outp test_expect_success 'git repack' 'git repack' test_expect_success 'git prune-packed' 'git prune-packed' -test_expect_failure '-> only packed objects' 'find -type f .git/objects/[0-9a-f][0-9a-f]' +test_expect_failure '-> only packed objects' '/usr/bin/find -type f .git/objects/[0-9a-f][0-9a-f]' test_done diff --git a/t/t2001-checkout-cache-clash.sh b/t/t2001-checkout-cache-clash.sh index 825119b01c..05c2262466 100755 --- a/t/t2001-checkout-cache-clash.sh +++ b/t/t2001-checkout-cache-clash.sh @@ -23,7 +23,7 @@ the symlink path1 and create directory path1 and file path1/file1. show_files() { # show filesystem files, just [-dl] for type and name - find path? -ls | + /usr/bin/find path? -ls | sed -e 's/^[0-9]* * [0-9]* * \([-bcdl]\)[^ ]* *[0-9]* *[^ ]* *[^ ]* *[0-9]* [A-Z][a-z][a-z] [0-9][0-9] [^ ]* /fs: \1 /' # what's in the cache, just mode and name git-ls-files --stage | diff --git a/t/t3100-ls-tree-restrict.sh b/t/t3100-ls-tree-restrict.sh index 8ca1a8a1d5..40501798d1 100755 --- a/t/t3100-ls-tree-restrict.sh +++ b/t/t3100-ls-tree-restrict.sh @@ -38,7 +38,7 @@ test_expect_success \ echo Lo >path2/foo && ln -s ../path1 path2/bazbo && echo Mi >path2/baz/b && - find path? \( -type f -o -type l \) -print | + /usr/bin/find path? \( -type f -o -type l \) -print | xargs git-update-index --add && tree=`git-write-tree` && echo $tree' diff --git a/t/t3101-ls-tree-dirname.sh b/t/t3101-ls-tree-dirname.sh index 087929a4bf..eb3df85eff 100755 --- a/t/t3101-ls-tree-dirname.sh +++ b/t/t3101-ls-tree-dirname.sh @@ -34,7 +34,7 @@ test_expect_success \ mkdir path3 && echo 111 >path3/1.txt && echo 222 >path3/2.txt && - find *.txt path* \( -type f -o -type l \) -print | + /usr/bin/find *.txt path* \( -type f -o -type l \) -print | xargs git-update-index --add && tree=`git-write-tree` && echo $tree' diff --git a/t/t4112-apply-renames.sh b/t/t4112-apply-renames.sh index 69e9603c78..bfcb8821c8 100755 --- a/t/t4112-apply-renames.sh +++ b/t/t4112-apply-renames.sh @@ -115,7 +115,7 @@ rename to include/arch/m32r/klibc/archsetjmp.h +#endif /* _KLIBC_ARCHSETJMP_H */ EOF -find klibc -type f -print | xargs git-update-index --add -- +/usr/bin/find klibc -type f -print | xargs git-update-index --add -- test_expect_success 'check rename/copy patch' 'git-apply --check patch' diff --git a/t/t5000-tar-tree.sh b/t/t5000-tar-tree.sh index b00acafce0..f46ea1542e 100755 --- a/t/t5000-tar-tree.sh +++ b/t/t5000-tar-tree.sh @@ -45,12 +45,12 @@ test_expect_success \ (p=long_path_to_a_file && cd a && for depth in 1 2 3 4 5; do mkdir $p && cd $p; done && echo text >file_with_long_path) && - (cd a && find .) | sort >a.lst' + (cd a && /usr/bin/find .) | sort >a.lst' test_expect_success \ 'add files to repository' \ - 'find a -type f | xargs git-update-index --add && - find a -type l | xargs git-update-index --add && + '/usr/bin/find a -type f | xargs git-update-index --add && + /usr/bin/find a -type l | xargs git-update-index --add && treeid=`git-write-tree` && echo $treeid >treeid && git-update-ref HEAD $(TZ=GMT GIT_COMMITTER_DATE="2005-05-27 22:00:00" \ @@ -79,7 +79,7 @@ test_expect_success \ test_expect_success \ 'validate filenames' \ - '(cd b/a && find .) | sort >b.lst && + '(cd b/a && /usr/bin/find .) | sort >b.lst && diff a.lst b.lst' test_expect_success \ @@ -96,7 +96,7 @@ test_expect_success \ test_expect_success \ 'validate filenames with prefix' \ - '(cd c/prefix/a && find .) | sort >c.lst && + '(cd c/prefix/a && /usr/bin/find .) | sort >c.lst && diff a.lst c.lst' test_expect_success \ @@ -113,7 +113,7 @@ test_expect_success \ test_expect_success \ 'validate filenames' \ - '(cd d/a && find .) | sort >d.lst && + '(cd d/a && /usr/bin/find .) | sort >d.lst && diff a.lst d.lst' test_expect_success \ @@ -130,7 +130,7 @@ test_expect_success \ test_expect_success \ 'validate filenames with prefix' \ - '(cd e/prefix/a && find .) | sort >e.lst && + '(cd e/prefix/a && /usr/bin/find .) | sort >e.lst && diff a.lst e.lst' test_expect_success \ diff --git a/t/t5300-pack-object.sh b/t/t5300-pack-object.sh index aafb976a75..c1d34de954 100755 --- a/t/t5300-pack-object.sh +++ b/t/t5300-pack-object.sh @@ -75,7 +75,7 @@ cd "$TRASH/.git2" test_expect_success \ 'check unpack without delta' \ - '(cd ../.git && find objects -type f -print) | + '(cd ../.git && /usr/bin/find objects -type f -print) | while read path do cmp $path ../.git/$path || { @@ -105,7 +105,7 @@ unset GIT_OBJECT_DIRECTORY cd "$TRASH/.git2" test_expect_success \ 'check unpack with REF_DELTA' \ - '(cd ../.git && find objects -type f -print) | + '(cd ../.git && /usr/bin/find objects -type f -print) | while read path do cmp $path ../.git/$path || { @@ -135,7 +135,7 @@ unset GIT_OBJECT_DIRECTORY cd "$TRASH/.git2" test_expect_success \ 'check unpack with OFS_DELTA' \ - '(cd ../.git && find objects -type f -print) | + '(cd ../.git && /usr/bin/find objects -type f -print) | while read path do cmp $path ../.git/$path || { diff --git a/t/t9200-git-cvsexportcommit.sh b/t/t9200-git-cvsexportcommit.sh index 4efa0c926c..e91b5a8437 100755 --- a/t/t9200-git-cvsexportcommit.sh +++ b/t/t9200-git-cvsexportcommit.sh @@ -174,7 +174,7 @@ test_expect_success \ if p="Å/goo/a/b/c/d/e/f/g/h/i/j/k/l/m/n/o/p/q/r/s/t/u/v/w/x/y/z/å/ä/ö" && mkdir -p "tst/$p" && date >"tst/$p/day" && - found=$(find tst -type f -print) && + found=$(/usr/bin/find tst -type f -print) && test "z$found" = "ztst/$p/day" && rm -fr tst then