changeset 39230:27bbd62e9957

zsh_completion: rename _hg_style_opts to _hg_template_opts --style is a deprecated alias for --template, and doesn't show up in help without --verbose, so completing it doesn't make much sense. Let's s/style/template/ this variable to be more consistent with cmdutil.py, which is helpful to look at in parallel next time someone wants to update the completion rules. Differential Revision: https://phab.mercurial-scm.org/D4261
author Anton Shestakov <av6@dwimlabs.net>
date Fri, 10 Aug 2018 08:19:36 +0800
parents 45e05d39d9ce
children fd17590655cf
files contrib/zsh_completion
diffstat 1 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/zsh_completion	Fri Aug 17 00:51:46 2018 +0200
+++ b/contrib/zsh_completion	Fri Aug 10 08:19:36 2018 +0800
@@ -424,12 +424,12 @@
   '(--ignore-space-change -b)'{-b,--ignore-space-change}'[ignore changes in the amount of white space]'
   '(--ignore-blank-lines -B)'{-B,--ignore-blank-lines}'[ignore changes whose lines are all blank]')
 
-_hg_style_opts=(
-  '--style[display using template map file]:'
-  '--template[display with template]:')
+_hg_template_opts=(
+  '--template[display with template]:template'
+)
 
 _hg_log_opts=(
-  $_hg_global_opts $_hg_style_opts $_hg_gitlike_opts
+  $_hg_global_opts $_hg_template_opts $_hg_gitlike_opts
   '(--limit -l)'{-l+,--limit=}'[limit number of changes displayed]:'
   '(--no-merges -M)'{-M,--no-merges}'[do not show merges]'
   '(--patch -p)'{-p,--patch}'[show patch]'
@@ -642,7 +642,7 @@
 }
 
 _hg_cmd_heads() {
-  _arguments -s -w : $_hg_global_opts $_hg_style_opts \
+  _arguments -s -w : $_hg_global_opts $_hg_template_opts \
   '(--topo -t)'{-t,--topo}'[show topological heads only]' \
   '(--closed -c)'{-c,--closed}'[show normal and closed branch heads]' \
   '(--rev -r)'{-r+,--rev=}'[show only heads which are descendants of rev]:revision:_hg_labels'
@@ -745,7 +745,7 @@
 }
 
 _hg_cmd_parents() {
-  _arguments -s -w : $_hg_global_opts $_hg_style_opts \
+  _arguments -s -w : $_hg_global_opts $_hg_template_opts \
   '(--rev -r)'{-r+,--rev=}'[show parents of the specified rev]:revision:_hg_labels' \
   ':last modified file:_hg_files'
 }
@@ -905,7 +905,7 @@
 }
 
 _hg_cmd_tip() {
-  _arguments -s -w : $_hg_global_opts $_hg_gitlike_opts $_hg_style_opts \
+  _arguments -s -w : $_hg_global_opts $_hg_gitlike_opts $_hg_template_opts \
   '(--patch -p)'{-p,--patch}'[show patch]'
 }