Skip to content
This repository has been archived by the owner on Sep 8, 2022. It is now read-only.

Substring match #5

Merged
merged 2 commits into from
Dec 4, 2018
Merged

Substring match #5

merged 2 commits into from
Dec 4, 2018

Conversation

marcsauter
Copy link
Contributor

Make kubectl-ns deal with substring matches

Show all namespaces:
$ kubectl ns
...

Show all substring matches:
$ kubectl ns kube
kube-ces
kube-ces-test
kube-deployment
kube-ingress
kube-keel
kube-log
kube-monkey
kube-nurse
kube-prometheus
kube-public
kube-state-metrics
kube-system
kube-trident

Set namespace if there is only one match:
$ kubectl ns system
namespace set to "kube-system"

Set namespace if there is an exact match:
$ kubectl ns kube-ces
namespace set to "kube-ces"

@ghouscht ghouscht merged commit 79b7c7d into master Dec 4, 2018
@ghouscht ghouscht deleted the substring-match branch December 12, 2019 09:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants