-
-
Notifications
You must be signed in to change notification settings - Fork 270
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support for custom Kubernetes cluster name shortening with regex
Adds two new flags: * - `-shorten-kube-names-regex-match` * - `-shorten-kube-names-regex-template` (defaults to `${1}`) Examples: Assume a kubernetes cluster named `myorg-region-profile-cluster-01` Using the default template: ```console powerline-go -shorten-kube-names-regex-match '^myorg-\w+-\w+-(.*)' ``` result: `cluster-01` Using a custom template: ```console powerline-go -shorten-kube-names-regex-match '^myorg-(\w+)-\w+-(.*)' -shorten-kube-names-regex-template '${1}/${2}' ``` result: `region/cluster-01`
- Loading branch information
Showing
6 changed files
with
134 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters