mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-08 04:34:00 +02:00
Add auto-completion for puppet node:
Provides auto-complete options for puppet node sub-command.
This commit is contained in:
parent
cc4294dd45
commit
5b354cf280
1 changed files with 34 additions and 0 deletions
|
|
@ -392,6 +392,18 @@ _module_arguments=(
|
|||
'--modulepath:$basemodulepath The search path for modules'
|
||||
)
|
||||
|
||||
local -a _node_arguments
|
||||
_node_arguments=(
|
||||
'clean:Clean up everything a puppetmaster knows about a node'
|
||||
'find:Retrieve a node object'
|
||||
'info:Print the default terminus class for this face'
|
||||
'--render-as:FORMAT The rendering format to use'
|
||||
'--verbose:Whether to log verbosely'
|
||||
'--debug:Whether to log debug information'
|
||||
'--extra:HASH Extra arguments to pass to the indirection request'
|
||||
'--terminus: TERMINUS The indirector terminus to use'
|
||||
)
|
||||
|
||||
|
||||
|
||||
__task_list ()
|
||||
|
|
@ -795,6 +807,23 @@ __puppet-module ()
|
|||
esac
|
||||
}
|
||||
|
||||
__puppet-node ()
|
||||
{
|
||||
local curcontext="$curcontext" state line
|
||||
typeset -A opt_args
|
||||
|
||||
_arguments -C \
|
||||
':command:->command' \
|
||||
'*::options:->options'
|
||||
|
||||
case $state in
|
||||
(command)
|
||||
_describe -t commands "gem subcommand" _node_arguments
|
||||
return
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
|
||||
|
||||
local expl
|
||||
|
|
@ -934,6 +963,11 @@ case $state in
|
|||
(module)
|
||||
__puppet-module
|
||||
;;
|
||||
|
||||
# Display sub-commands for puppet node.
|
||||
(node)
|
||||
__puppet-node
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue