tag 506876 +patch thanks A possible patch would be to just return whatever in del_unreferenced if the %list hash is empty. That way the tar command never gets executed (which seems to be appropriate since there is nothing to do then). It's a little late now, so I can't promise that it actually works. I'll test it tomorrow or so but maybe someone wants to have a look at it. Patch is attached.
Hauke
Index: svn-inject =================================================================== --- svn-inject (revision 11968) +++ svn-inject (working copy) @@ -436,9 +436,11 @@ my $dir=Cwd::abs_path(shift); my %list = shift; chomp(my $tmpdir = `mktemp -d`); + # get out if %list is empty! + return 1 if keys(%list) == 0; # withecho("cp", "-a", "--parents", (keys %ourfiles), "../current2"); sucks, cannot ignore errors "properly" # this sucks too - withecho("cd $dir ; tar $opt_tarquiet -c ".join(' ',keys %ourfiles)." 2>/dev/null | tar x $opt_tarquiet -C $tmpdir"); + withecho("cd $dir ; tar $opt_tarquiet -c ".join(' ',keys %list)." 2>/dev/null | tar x $opt_tarquiet -C $tmpdir"); withecho("rm", "-rf", $dir); withecho("mv", $tmpdir, $dir); }
signature.asc
Description: Digital signature