Puppet: use puppet terminology
Usage: puppet <subcommand> [options] <action> [options]
This commit is contained in:
parent
54d53c6227
commit
ac98c31f30
@ -50,7 +50,7 @@ _puppet()
|
|||||||
local cur prev words cword
|
local cur prev words cword
|
||||||
_init_completion || return
|
_init_completion || return
|
||||||
|
|
||||||
local xspec helpopts command subcommand
|
local xspec helpopts subcommand action
|
||||||
|
|
||||||
case $prev in
|
case $prev in
|
||||||
--help)
|
--help)
|
||||||
@ -60,39 +60,39 @@ _puppet()
|
|||||||
|
|
||||||
case ${words[0]} in
|
case ${words[0]} in
|
||||||
puppetmasterd)
|
puppetmasterd)
|
||||||
command=master
|
subcommand=master
|
||||||
;;
|
;;
|
||||||
puppetd)
|
puppetd)
|
||||||
command=agent
|
subcommand=agent
|
||||||
;;
|
;;
|
||||||
puppetca)
|
puppetca)
|
||||||
command=cert
|
subcommand=cert
|
||||||
;;
|
;;
|
||||||
ralsh)
|
ralsh)
|
||||||
command=resource
|
subcommand=resource
|
||||||
;;
|
;;
|
||||||
puppetrun)
|
puppetrun)
|
||||||
command=kick
|
subcommand=kick
|
||||||
;;
|
;;
|
||||||
puppetqd)
|
puppetqd)
|
||||||
command=queue
|
subcommand=queue
|
||||||
;;
|
;;
|
||||||
filebucket)
|
filebucket)
|
||||||
command=filebucket
|
subcommand=filebucket
|
||||||
;;
|
;;
|
||||||
puppetdoc)
|
puppetdoc)
|
||||||
command=doc
|
subcommand=doc
|
||||||
;;
|
;;
|
||||||
pi)
|
pi)
|
||||||
command=describe
|
subcommand=describe
|
||||||
;;
|
;;
|
||||||
puppet)
|
puppet)
|
||||||
case ${words[1]} in
|
case ${words[1]} in
|
||||||
agent|apply|cert|describe|doc|filebucket|kick|master|queue|resource)
|
agent|apply|cert|describe|doc|filebucket|kick|master|queue|resource)
|
||||||
command=${words[1]}
|
subcommand=${words[1]}
|
||||||
;;
|
;;
|
||||||
*.pp|*.rb|-*)
|
*.pp|*.rb|-*)
|
||||||
command=apply
|
subcommand=apply
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
COMPREPLY=( $( compgen -W 'agent apply cert describe doc
|
COMPREPLY=( $( compgen -W 'agent apply cert describe doc
|
||||||
@ -102,7 +102,7 @@ _puppet()
|
|||||||
esac
|
esac
|
||||||
esac
|
esac
|
||||||
|
|
||||||
case $command in
|
case $subcommand in
|
||||||
agent)
|
agent)
|
||||||
case $prev in
|
case $prev in
|
||||||
--fqdn)
|
--fqdn)
|
||||||
@ -159,10 +159,10 @@ _puppet()
|
|||||||
return 0
|
return 0
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
subcommand=$prev
|
action=$prev
|
||||||
COMPREPLY=( $( compgen -W '--digest --debug --verbose' \
|
COMPREPLY=( $( compgen -W '--digest --debug --verbose' \
|
||||||
-- "$cur" ) )
|
-- "$cur" ) )
|
||||||
case $subcommand in
|
case $action in
|
||||||
--generate)
|
--generate)
|
||||||
_known_hosts_real "$cur"
|
_known_hosts_real "$cur"
|
||||||
return 0
|
return 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user