Commit Graph

12 Commits (750881c0ab62a9f59d53582bc33826caa167aa83)

Author SHA1 Message Date
Xiang Dai 36065c6dd7 delete all duplicate empty blanks
Signed-off-by: Xiang Dai <764524258@qq.com>
2019-02-23 10:28:04 +08:00
Pingan2017 672cad60e9 code cleanup for kubectl config 2018-12-25 15:24:57 +08:00
Yang Li 141d33a2a5 Fix some golint errors for packages in `pkg/kubectl/cmd`
Co-authored-by: Arijit Basu <sayanarijit@gmail.com>
2018-11-22 22:09:08 +08:00
Maciej Szulik 21789b85a6
Move pkg/kubectl/cmd/templates -> pkg/kubectl/util/temlpates 2018-10-11 22:01:03 +02:00
Christoph Blecker 97b2992dc1
Update gofmt for go1.11 2018-10-05 12:59:38 -07:00
Di Xu 1c715d51c4 some code change
fix wrong required flags

disable the addition of [flags] to the usage, use customized useline

fix function rename
2017-12-25 16:23:38 +08:00
Kubernetes Submit Queue 79d858660c
Merge pull request #55044 from ahmetb/wording
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

kubectl/config/rename: fix wording

Using `Context %q renamed to %q.` in rename-context to be consistent with other
commands like delete-context, set-context, use-context.

/sig cli
/release-note none
2017-11-09 01:52:26 -08:00
Ahmet Alp Balkan d7b0890217
kubectl/config/rename: fix wording
Using "Context %q renamed to %q." in rename-context to be consistent with other
commands like delete-context, set-context, use-context.

Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2017-11-02 21:10:11 -07:00
Cao Shufeng 26032ad6f8 [cli] exit when Validate() return an error
cmdutil.UsageErrorf() does nothing but return a string. When Validate()
returns an error, we should call exit() function.
2017-11-02 14:51:28 +08:00
zhengjiajin e62bc0b7c8 fix issue(11233)enhance kubectl config command 2017-09-14 17:14:42 +08:00
Alexander Campbell 6fd36c10ad kubectl/cmd: many small refactors
* Rename variables and functions to match Go convention.
   For example, UsageError --> UsageErrorf.
 * Remove redundant or unreachable code.
 * Simplify some utility functions (no functionality changes).
 * Fix hanging 'if { return } else { return }' constructs.
 * Fix several incorrect printf verbs.
2017-06-27 16:25:20 -07:00
Arthur Miranda 83fec5bafb Add `kubeclt config rename-context`
Enables renaming of a context via `kubectl`

Fix https://github.com/kubernetes/kubernetes/issues/45131
2017-05-26 15:49:30 -03:00