@@ -241,7 +241,7 @@ private function commit_changeset( $p_repo, $p_input, $p_branch='' ) {
241241 if ( strpos ( $ t_line , '# ' ) === 0 ) {
242242 if ( !isset ( $ t_commit ['revision ' ] ) && preg_match ( '@^# Node ID +([a-f0-9]+)@ ' , $ t_line , $ t_matches ) ) {
243243 $ t_commit ['revision ' ] = $ t_matches [1 ];
244- echo 'Processing ' . string_display_line ( $ t_commit [revision] ) . '... ' ;
244+ echo 'Processing ' . string_display_line ( $ t_commit [' revision ' ] ) . '... ' ;
245245 if ( SourceChangeset::exists ( $ p_repo ->id , $ t_commit ['revision ' ] ) ) {
246246 echo "already exists. \n" ;
247247 return array ( null , array () );
@@ -285,21 +285,21 @@ private function commit_changeset( $p_repo, $p_input, $p_branch='' ) {
285285 $ t_file ['revision ' ] = $ t_commit ['revision ' ];
286286
287287 if (!empty ($ t_file_matches [3 ])) {
288- if (! empty ($ t_file_matches [5 ])) {
289- $ t_file ['action ' ] = 'bin ' ;
288+ if ( empty ($ t_file_matches [5 ]) && empty ( $ t_file_matches [ 6 ]) && empty ( $ t_file_matches [ 7 ])) {
289+ $ t_file ['action ' ] = 'mod ' ;
290290 }
291- else if ( " /dev/null " == $ t_file_matches [7 ] ) {
292- $ t_file ['action ' ] = 'rm ' ;
291+ else if (! empty ( $ t_file_matches [5 ]) ) {
292+ $ t_file ['action ' ] = 'bin ' ;
293293 }
294294 else if ("/dev/null " == $ t_file_matches [6 ]) {
295295 $ t_file ['action ' ] = 'add ' ;
296296 }
297+ else if ("/dev/null " == $ t_file_matches [7 ]) {
298+ $ t_file ['action ' ] = 'rm ' ;
299+ }
297300 else if ("/dev/null " == $ t_file_matches [7 ] && "/dev/null " == $ t_file_matches [6 ]) {
298301 $ t_file ['action ' ] = 'n/a ' ;
299302 }
300- else if (empty ($ t_file_matches [5 ]) && empty ($ t_file_matches [6 ]) && empty ($ t_file_matches [7 ])) {
301- $ t_file ['action ' ] = 'mod ' ;
302- }
303303 }
304304 $ t_commit ['files ' ][] = $ t_file ;
305305 }
0 commit comments