can we pull in git as a dependency for xfstests?
xfs/073 has been failing for me for a while on most of my test setups with:
diff: memory exhausted
from the recursive diff. Switching to the significantly more memory efficient implementation in git diff as in the patch below fixes this.
Would it be ok to pull in diff (including a supported check)?
tests/xfs/073 +1 -1
@@ -76,7 +76,7 @@ _verify_copy() fi echo comparing new image files to old - diff -Naur $source_dir $target_dir + git diff --no-index $source_dir $target_dir echo comparing new image directories to old find $source_dir | _filter_path $source_dir > $tmp.manifest1
Quoted 15 lines · Christoph Hellwig
xfs/073 has been failing for me for a while on most of my test setups with:
diff: memory exhausted
from the recursive diff. Switching to the significantly more memory efficient implementation in git diff as in the patch below fixes this.
Would it be ok to pull in diff (including a supported check)?
tests/xfs/073 +0
-0
tests/xfs/073 _verify_copy() · line 79
Quoted 5 lines
tests/xfs/073 +1
-1@@ -76,7 +76,7 @@ _verify_copy() fi echo comparing new image files to old - diff -Naur $source_dir $target_dir + git diff --no-index $source_dir $target_dir
How about
(cd $source_dir ; find . -type f -print0 | xargs -0 md5sum) | \ (cd $target_dir ; md5sum -c --quiet)
since 073.out doesn't contain any diff output?
--D
Quoted 4 lines
tests/xfs/073 +0
-0echo comparing new image directories to old find $source_dir | _filter_path $source_dir > $tmp.manifest1
Quoted 9 lines · Darrick J. Wong
tests/xfs/073 _verify_copy() · line 79
Quoted 2 lines
tests/xfs/073 +1
-1- diff -Naur $source_dir $target_dir + git diff --no-index $source_dir $target_dirHow about
(cd $source_dir ; find . -type f -print0 | xargs -0 md5sum) | \ (cd $target_dir ; md5sum -c --quiet)since 073.out doesn't contain any diff output?
That works fine as well for me.
Quoted 15 lines · Christoph Hellwig
xfs/073 has been failing for me for a while on most of my test setups with:
diff: memory exhausted
from the recursive diff. Switching to the significantly more memory efficient implementation in git diff as in the patch below fixes this.
Would it be ok to pull in diff (including a supported check)?
tests/xfs/073 +0
-0
tests/xfs/073 _verify_copy() · line 79
Quoted 5 lines
tests/xfs/073 +1
-1@@ -76,7 +76,7 @@ _verify_copy() fi echo comparing new image files to old - diff -Naur $source_dir $target_dir + git diff --no-index $source_dir $target_dir
The "diff" is more widespread, if we can use diff, better to not bring in a new necessary dependence. But you can make it to be optional if you need. Likes:
_diff()
{
local cmd="git diff"
grep -wq -- "--no-index" <($cmd --help 2>/dev/null)
if [ $? -ne 0 ];then
cmd=diff
else
cmd="$cmd --no-index"
if
$cmd $*
}But there might be some incompatible options betweeen "diff" and "git diff".
Thanks,
Zorro
Quoted 4 lines
tests/xfs/073 +0
-0echo comparing new image directories to old find $source_dir | _filter_path $source_dir > $tmp.manifest1
Quoted 1 line · Zorro Lang
But there might be some incompatible options betweeen "diff" and "git diff".
Yes, many of the common diff options are not supported.
But I think the md5sum version from Darrick work just as fine, so I'll wait for him to submit that.