DORMANTno replies

[gitk PATCH 3/3] gitk: allow text-conversion in diffs

From: Jeff King <hidden>
Date: 2016-06-15 22:45:44
Subsystem: the rest · Maintainer: Linus Torvalds

The "textconv" feature of git requires explicit enabling in
plumbing because the resulting diffs are not useful for
feeding to "git-apply" or "patch". Thus any callers should
make a conscious choice that they want the human-friendly
version.

Since the diffs presented by gitk are meant primarily for
human consumption, and not applying, it makes sense to allow
text conversion.
---
Paul,

I am cc'ing you only on 3/3 since it is the only gitk patch (the others
implement --textconv in git itself). Textconv is basically a feature to
show human-readable text diffs of binary files by doing a one-way binary
to text conversion (and so they can't be applied).

I think gitk would always want to support these; if not, then the
alternative is a "diff flags" option for gitk where the user could
specify this flag manually.

 gitk |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/gitk b/gitk
index a5e24e4..0fb87c7 100755
--- a/gitk
+++ b/gitk
@@ -7198,7 +7198,7 @@ proc getblobdiffs {ids} {
     global limitdiffs vfilelimit curview
     global diffencoding targetline diffnparents
 
-    set cmd [diffcmd $ids "-p -C --cc --no-commit-id -U$diffcontext"]
+    set cmd [diffcmd $ids "-p -C --cc --no-commit-id -U$diffcontext --textconv"]
     if {$ignorespace} {
 	append cmd " -w"
     }
-- 
1.6.1.rc2.285.gc1cf2
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help