summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--Completion/Unix/Command/_git22
2 files changed, 25 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 4655c8090..de05edaf0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2007-08-04 Clint Adams <clint@zsh.org>
+ * Matthieu Moy: 23738: Completion/Unix/Command/_git: additional
+ git diff args.
+
* 23739: Completion/Unix/Command/_git: merge in git diff
completion fixes from Nikolai Weibull's repository.
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index 85be44246..93341ad31 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -22,17 +22,39 @@ typeset -ga diff_args
# TODO: -s and --diff-filter are undocumented
diff_args=(
+ '--abbrev-[Instead of showing the full object name, show only handful hexdigits prefix.]: :_guard "[[\:digit\:]]#" number'
+ '--binary[In addition to --full-index, output "binary diff" that can be applied with "git apply".]'
+ '(-c --cached)'{-c,--cached}'[show cached files in the output]'
+ '--color-words[Show colored word diff, i.e. color words which have changed.]'
+ '--color[Show colored diff.]'
'--diff-filter=-[filter to apply to diff]'
'--find-copies-harder[try harder to find copies]'
'--name-only[show only names of changed files]'
'--name-status[show only names and status of changed files]'
+ '--no-color[Turn off colored diff, even when the configuration file gives the default to color output.]'
+ '--no-renames[Turn off rename detection, even when the configuration file gives the default to do so.]'
+ '--numstat[Similar to --stat, but shows numbers in decimal notation and pathname without abbreviation.]'
+ '--patch-with-raw[Synonym for "-p --raw".]'
+ '--patch-with-stat[Synonym for "-p --stat".]'
'--pickaxe-all[when -S finds a change, show all changes in that changeset]'
+ '--pickaxe-regex[Make the <string> not a plain string but an extended POSIX regex to match.]'
+ '--raw[Generate the raw format.]'
+ '--stat[Generate a diffstat.]'
+ '--summary[Output a condensed summary of extended header information such as creations, renames and mode changes.]'
+ '--text[Treat all files as text.]'
+ '(-1 --base)'{-1,--base}'[Diff against the base version]'
+ '(-2 --base)'{-2,--ours}'[Diff against our branch version]'
+ '(-3 --base)'{-3,--theirs}'[Diff against their branch version]'
+ '-0[omit diff output for unmerged entries and just show "Unmerged".]'
+ '-a[Shorthand for "--text".]'
+ '--full-index[Instead of the first handful characters, show full object name of pre- and post-image blob on the "index" line when generating a patch format output.]'
'-B-[break complete rewrite changes into pairs of given size]: :_guard "[[\:digit\:]]#" size'
'-C-[detect copies as well as renames with given score]: :_guard "[[\:digit\:]]#" size'
'-l-[number of rename/copy targets to run]: :_guard "[[\:digit\:]]#" number'
'-M-[detect renames with given score]: :_guard "[[\:digit\:]]#" size'
'-O-[output patch in the order of glob-pattern lines in given file]:file:_files'
'-p[generate diff in patch format]'
+ '-q[Remain silent even on nonexistent files]'
'-R[do a reverse diff]'
'-S-[look for differences that contain the given string]:string'
'-s[do not produce any output]'