|
30 | 30 | # Remember where GIT_DIR is before changing to CVS checkout |
31 | 31 | unless ($ENV{GIT_DIR}) { |
32 | 32 | # No GIT_DIR set. Figure it out for ourselves |
33 | | - my $gd =`git-rev-parse --git-dir`; |
| 33 | + my $gd =`git rev-parse --git-dir`; |
34 | 34 | chomp($gd); |
35 | 35 | $ENV{GIT_DIR} = $gd; |
36 | 36 | } |
|
66 | 66 | # resolve target commit |
67 | 67 | my $commit; |
68 | 68 | $commit = pop @ARGV; |
69 | | -$commit = safe_pipe_capture('git-rev-parse', '--verify', "$commit^0"); |
| 69 | +$commit = safe_pipe_capture('git', 'rev-parse', '--verify', "$commit^0"); |
70 | 70 | chomp $commit; |
71 | 71 | if ($?) { |
72 | 72 | die "The commit reference $commit did not resolve!"; |
|
76 | 76 | my $parent; |
77 | 77 | if (@ARGV) { |
78 | 78 | $parent = pop @ARGV; |
79 | | - $parent = safe_pipe_capture('git-rev-parse', '--verify', "$parent^0"); |
| 79 | + $parent = safe_pipe_capture('git', 'rev-parse', '--verify', "$parent^0"); |
80 | 80 | chomp $parent; |
81 | 81 | if ($?) { |
82 | 82 | die "The parent reference did not resolve!"; |
83 | 83 | } |
84 | 84 | } |
85 | 85 |
|
86 | 86 | # find parents from the commit itself |
87 | | -my @commit = safe_pipe_capture('git-cat-file', 'commit', $commit); |
| 87 | +my @commit = safe_pipe_capture('git', 'cat-file', 'commit', $commit); |
88 | 88 | my @parents; |
89 | 89 | my $committer; |
90 | 90 | my $author; |
|
162 | 162 | close MSG; |
163 | 163 |
|
164 | 164 | if ($parent eq $noparent) { |
165 | | - `git-diff-tree --binary -p --root $commit >.cvsexportcommit.diff`;# || die "Cannot diff"; |
| 165 | + `git diff-tree --binary -p --root $commit >.cvsexportcommit.diff`;# || die "Cannot diff"; |
166 | 166 | } else { |
167 | | - `git-diff-tree --binary -p $parent $commit >.cvsexportcommit.diff`;# || die "Cannot diff"; |
| 167 | + `git diff-tree --binary -p $parent $commit >.cvsexportcommit.diff`;# || die "Cannot diff"; |
168 | 168 | } |
169 | 169 |
|
170 | 170 | ## apply non-binary changes |
|
178 | 178 | print "Checking if patch will apply\n"; |
179 | 179 |
|
180 | 180 | my @stat; |
181 | | -open APPLY, "GIT_INDEX_FILE=$tmpdir/index git-apply $context --summary --numstat<.cvsexportcommit.diff|" || die "cannot patch"; |
| 181 | +open APPLY, "GIT_INDEX_FILE=$tmpdir/index git apply $context --summary --numstat<.cvsexportcommit.diff|" || die "cannot patch"; |
182 | 182 | @stat=<APPLY>; |
183 | 183 | close APPLY || die "Cannot patch"; |
184 | 184 | my (@bfiles,@files,@afiles,@dfiles); |
|
333 | 333 | if ($opt_W) { |
334 | 334 | system("git checkout -q $commit^0") && die "cannot patch"; |
335 | 335 | } else { |
336 | | - `GIT_INDEX_FILE=$tmpdir/index git-apply $context --summary --numstat --apply <.cvsexportcommit.diff` || die "cannot patch"; |
| 336 | + `GIT_INDEX_FILE=$tmpdir/index git apply $context --summary --numstat --apply <.cvsexportcommit.diff` || die "cannot patch"; |
337 | 337 | } |
338 | 338 |
|
339 | 339 | print "Patch applied successfully. Adding new files and directories to CVS\n"; |
|
0 commit comments