pack-objects: name pack files after trailer hash
[gitweb.git] / git-add--interactive.perl
index 531095916f959f47cc3fca38bafe9cbef604c0d9..51563840f49089cf250992fd47fe70a45cef0c52 100755 (executable)
@@ -169,7 +169,7 @@ sub colored {
 my %patch_mode_flavour = %{$patch_modes{stage}};
 
 sub run_cmd_pipe {
-       if ($^O eq 'MSWin32' || $^O eq 'msys') {
+       if ($^O eq 'MSWin32') {
                my @invalid = grep {m/[":*]/} @_;
                die "$^O does not support: @invalid\n" if @invalid;
                my @args = map { m/ /o ? "\"$_\"": $_ } @_;
@@ -734,7 +734,7 @@ sub parse_diff {
        my ($path) = @_;
        my @diff_cmd = split(" ", $patch_mode_flavour{DIFF});
        if (defined $diff_algorithm) {
-               push @diff_cmd, "--diff-algorithm=${diff_algorithm}";
+               splice @diff_cmd, 1, 0, "--diff-algorithm=${diff_algorithm}";
        }
        if (defined $patch_mode_revision) {
                push @diff_cmd, $patch_mode_revision;