From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24515 invoked from network); 3 Aug 2007 15:12:43 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.1 (2007-05-02) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00 autolearn=ham version=3.2.1 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 3 Aug 2007 15:12:43 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 84368 invoked from network); 3 Aug 2007 15:12:37 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 3 Aug 2007 15:12:37 -0000 Received: (qmail 25562 invoked by alias); 3 Aug 2007 15:12:34 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 23738 Received: (qmail 28106 invoked from network); 3 Aug 2007 12:57:31 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 3 Aug 2007 12:57:31 -0000 Received: (qmail 93535 invoked from network); 3 Aug 2007 12:57:30 -0000 Received: from imag.imag.fr (129.88.30.1) by a.mx.sunsite.dk with SMTP; 3 Aug 2007 12:57:27 -0000 Received: from mail-veri.imag.fr (mail-veri.imag.fr [129.88.43.52]) by imag.imag.fr (8.13.8/8.13.8) with ESMTP id l73Cv0sC012037 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO); Fri, 3 Aug 2007 14:57:02 +0200 (CEST) Received: from bauges.imag.fr ([129.88.43.5]) by mail-veri.imag.fr with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA:32) (Exim 4.50) id 1IGwiB-00047g-VI; Fri, 03 Aug 2007 14:57:00 +0200 Received: from moy by bauges.imag.fr with local (Exim 4.63) (envelope-from ) id 1IGwiB-0002Py-Sy; Fri, 03 Aug 2007 14:56:59 +0200 To: zsh-workers@sunsite.dk Subject: [PATCH] Many missing options for git-diff zsh completion From: Matthieu Moy Date: Fri, 03 Aug 2007 14:56:59 +0200 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.97 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: Matthieu Moy X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (imag.imag.fr [129.88.30.1]); Fri, 03 Aug 2007 14:57:02 +0200 (CEST) X-IMAG-MailScanner-Information: Please contact IMAG DMI for more information X-IMAG-MailScanner: Found to be clean X-IMAG-MailScanner-SpamCheck: X-IMAG-MailScanner-From: moy@imag.fr Hi, git-diff has a lot more options that the latest _git file has. Here's a patch that adds them (feel free to remove a few of them if you do not believe they're common enough, but the list seems fine as it is). Please, Cc me in your replies, I'm not a list subscriber. Thanks, -- Matthieu --- Completion/Unix/_git 2007-08-03 12:50:05 +0000 +++ Completion/Unix/_git 2007-08-03 12:50:15 +0000 @@ -22,17 +22,39 @@ # 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 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]'