mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
Merge pull request #13415 from JanetKuo/kubectl-rolling-bash-completion
Enable kubectl rolling-update rc name bash completion
This commit is contained in:
commit
b6aac3633d
@ -186,6 +186,11 @@ __kubectl_get_resource_pod()
|
|||||||
__kubectl_parse_get "pod"
|
__kubectl_parse_get "pod"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
__kubectl_get_resource_rc()
|
||||||
|
{
|
||||||
|
__kubectl_parse_get "rc"
|
||||||
|
}
|
||||||
|
|
||||||
# $1 is the name of the pod we want to get the list of containers inside
|
# $1 is the name of the pod we want to get the list of containers inside
|
||||||
__kubectl_get_containers()
|
__kubectl_get_containers()
|
||||||
{
|
{
|
||||||
@ -229,6 +234,10 @@ __custom_func() {
|
|||||||
__kubectl_get_resource_pod
|
__kubectl_get_resource_pod
|
||||||
return
|
return
|
||||||
;;
|
;;
|
||||||
|
kubectl_rolling-update)
|
||||||
|
__kubectl_get_resource_rc
|
||||||
|
return
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
@ -52,6 +52,11 @@ __kubectl_get_resource_pod()
|
|||||||
__kubectl_parse_get "pod"
|
__kubectl_parse_get "pod"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
__kubectl_get_resource_rc()
|
||||||
|
{
|
||||||
|
__kubectl_parse_get "rc"
|
||||||
|
}
|
||||||
|
|
||||||
# $1 is the name of the pod we want to get the list of containers inside
|
# $1 is the name of the pod we want to get the list of containers inside
|
||||||
__kubectl_get_containers()
|
__kubectl_get_containers()
|
||||||
{
|
{
|
||||||
@ -95,6 +100,10 @@ __custom_func() {
|
|||||||
__kubectl_get_resource_pod
|
__kubectl_get_resource_pod
|
||||||
return
|
return
|
||||||
;;
|
;;
|
||||||
|
kubectl_rolling-update)
|
||||||
|
__kubectl_get_resource_rc
|
||||||
|
return
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
Loading…
Reference in New Issue
Block a user