diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-11-27 05:06:31 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-11-27 05:06:31 +0300 |
commit | 10f65c239a885336b745cc9d2e1654980ffef41e (patch) | |
tree | f10ffd064f85e27f3ff8b64e0d26e179df8bca77 /diff.c | |
parent | 14c63a9dc093d6738454f6369a4f5663ca732cf7 (diff) | |
parent | e9282f02b2f21118f3383608718e38efc3d967e1 (diff) |
Merge branch 'jc/ignore-cr-at-eol'
The "diff" family of commands learned to ignore differences in
carriage return at the end of line.
* jc/ignore-cr-at-eol:
diff: --ignore-cr-at-eol
xdiff: reassign xpparm_t.flags bits
Diffstat (limited to 'diff.c')
-rw-r--r-- | diff.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -4129,9 +4129,7 @@ void diff_setup_done(struct diff_options *options) * inside contents. */ - if (DIFF_XDL_TST(options, IGNORE_WHITESPACE) || - DIFF_XDL_TST(options, IGNORE_WHITESPACE_CHANGE) || - DIFF_XDL_TST(options, IGNORE_WHITESPACE_AT_EOL)) + if ((options->xdl_opts & XDF_WHITESPACE_FLAGS)) options->flags.diff_from_contents = 1; else options->flags.diff_from_contents = 0; @@ -4588,6 +4586,8 @@ int diff_opt_parse(struct diff_options *options, DIFF_XDL_SET(options, IGNORE_WHITESPACE_CHANGE); else if (!strcmp(arg, "--ignore-space-at-eol")) DIFF_XDL_SET(options, IGNORE_WHITESPACE_AT_EOL); + else if (!strcmp(arg, "--ignore-cr-at-eol")) + DIFF_XDL_SET(options, IGNORE_CR_AT_EOL); else if (!strcmp(arg, "--ignore-blank-lines")) DIFF_XDL_SET(options, IGNORE_BLANK_LINES); else if (!strcmp(arg, "--indent-heuristic")) |