Skip to content

Don't warn about missing EOL for symlinks

Michael J Gruber git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 17 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4diff/xdiff: refactor EOF-EOL detectiondiff.c xdiff/xutils.c+2 -59 replies
2/4diff: make treatment of missing EOL at EOF configurablecache.h diff.c+5 -30 replies
3/4diff: Do not warn about missing EOL at EOF for symlinksdiff.c t/t4030-diff-textconv.sh+2 -11 reply
4/4RFC: add whitespace rule for no-eol-at-eofws.c+1 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] Don't warn about missing EOL for symlinks

"No newline at end of file" always confuses me when looking at a diff for symlinks. "File? Huh? Didn't Git recognize my symlink?"

This mini series refactors the diff/xdiff code slightly to have the two occurences of the warning both in diff.c, introduces a whitespace flag WS_NO_EOL_AT_EOF to make this warning configurable, and actually changes the default behaviour to what is described thorougly along with the rationale in 3/4.

4/4 is a RFC - do we need to tweak this from config like other whitespace warnings? 4/4 is lacking the Doc change for now.

Michael J Gruber (4):
diff/xdiff: refactor EOF-EOL detection
diff: make treatment of missing EOL at EOF configurable
diff: Do not warn about missing EOL at EOF for symlinks
RFC: add whitespace rule for no-eol-at-eof

 cache.h                  |    3 ++-
 diff.c                   |    7 ++++++-
 t/t4030-diff-textconv.sh |    1 -
 ws.c                     |    1 +
 xdiff/xutils.c           |    5 -----
 5 files changed, 9 insertions(+), 8 deletions(-)