Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH] _git: offer changed files relative to current directory
- X-seq: zsh-workers 27455
- From: "Alexey I. Froloff" <raorn@xxxxxxxxxxxx>
- To: Zsh list <zsh-workers@xxxxxxx>
- Subject: [PATCH] _git: offer changed files relative to current directory
- Date: Sat, 5 Dec 2009 03:32:43 +0300
- Cc: "Alexey I. Froloff" <raorn@xxxxxxxxxxxx>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
__git_changed_files() behavior should match git-commit, pass --relative
to git-diff-index then looking for changed files.
Signed-off-by: Alexey I. Froloff <raorn@xxxxxxxxxxxx>
---
Completion/Unix/Command/_git | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index e483133..dd3617b 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -2826,7 +2826,7 @@ __git_unmerged_files () {
__git_changed_files () {
local -a files
- files=(${(ps:\0:)"$(_call_program files git diff-index -z --name-only --no-color HEAD 2>/dev/null)"})
+ files=(${(ps:\0:)"$(_call_program files git diff-index -z --name-only --no-color --relative HEAD 2>/dev/null)"})
__git_command_successful || return
_wanted files expl 'index file' _multi_parts $@ - / files
--
1.6.5.3
Messages sorted by:
Reverse Date,
Date,
Thread,
Author