From 415b5f4cc2ef54943d178bef0c55b2517afc6904 Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Thu, 9 Sep 1999 14:01:32 +0000 Subject: zsh-workers/7744 --- Completion/User/_patch | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Completion/User/_patch b/Completion/User/_patch index 9c5bc0269..6be2afd62 100644 --- a/Completion/User/_patch +++ b/Completion/User/_patch @@ -1,7 +1,9 @@ #compdef patch +local comp_p='compadd "$expl[@]" -S0 -r "1-9" - ""' + _arguments -s \ - '(--strip)-p+:number:(0)' \ + '(--strip)-p+:number:'"{$comp_p}" \ '(--fuzz)-F+:lines:' \ '(--context)-c' \ '(--ed)-e' \ @@ -30,7 +32,8 @@ _arguments -s \ ':original file:_files' \ ':patch file:_files' \ -- \ - '*=NUM*:number:(0)' \ + '*strip=NUM*:number:'"{$comp_p}" \ + '*get=NUM*:get files from RCS etc:' \ '*=LINES*:lines:' \ '*=PATCHFILE*:patch file:_files' \ '*=FILE*:file:_files' \ -- cgit 1.4.1