Unexpected result in git-diff

后端 未结 2 1620
无人及你
无人及你 2020-12-20 00:38

Why I get this patch:

@@ -129,8 +132,9 @@ sub _preprocess_message {
 sub _process_message {
     my ($self, $message) = @_;

-    my $method = ref($message)          


        
2条回答
  •  [愿得一人]
    2020-12-20 01:39

    git diff --patience produces the result that you expect. The method tries hard not to mark lines as added or removed when they did not change. It is not the default because it is computationally expensive. (And when the purpose is to generate a patch that is applied later, it does not matter most of the time whether a diff looks the one way or the other.)

提交回复
热议问题