k3s/docs
Kubernetes Submit Queue c19569f03f Merge pull request #34502 from fabianofranz/cli_usability_improvements
Automatic merge from submit-queue

Improvements to CLI usability and maintainability

Improves `kubectl` from an usability perspective by

1. Fixing how we handle terminal width in help. Some sections like the flags use the entire available width, while others like long descriptions breaks lines but don't follow a well established max width (screenshot below). This PR adds a new responsive writer that will adjust to terminal width and set 80, 100, or 120 columns as the max width, but not more than that given POSIX best practices and recommendations for better readability.
![terminal_width](https://cloud.githubusercontent.com/assets/158611/19253184/b23a983e-8f1f-11e6-9bae-667dd5981485.png)
2. Adds our own normalizers for long descriptions and cmd examples which allows us better control about how things like lists, paragraphs, line breaks, etc are printed. Features markdown support. Looks like `templates.LongDesc` and `templates.Examples` instead of `dedent.Dedend`.
3. Allows simple reordering and reuse of help and usage sections.
3. Adds `verify-cli-conventions.sh` which intends to run tests to make sure cmd developers are using what we propose as [kubectl conventions](https://github.com/kubernetes/kubernetes/blob/master/docs/devel/kubectl-conventions.md). Just a couple simple tests for now but the framework is there and it's easy to extend.
4. Update [kubectl conventions](https://github.com/kubernetes/kubernetes/blob/master/docs/devel/kubectl-conventions.md) to use our own normalizers instead of `dedent.Dedent`.

**Release note**:
<!--  Steps to write your release note:
1. Use the release-note-* labels to set the release note state (if you have access) 
2. Enter your extended release note in the below block; leaving it blank means using the PR title as the release note. If no release note is required, just write `NONE`. 
-->
```release-note
Improves how 'kubectl' uses the terminal size when printing help and usage.
```

@kubernetes/kubectl
2016-10-17 23:41:23 -07:00
..
admin Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00
api-reference Generated part for NumberReady 2016-10-12 15:36:01 +02:00
design Merge pull request #34758 from fgrzadkowski/monitoring_arch 2016-10-17 07:43:23 -07:00
devel Merge pull request #34502 from fabianofranz/cli_usability_improvements 2016-10-17 23:41:23 -07:00
getting-started-guides Delete vagrant.md 2016-09-27 17:02:14 -04:00
images
man/man1 Add 'kubectl set limit' 2016-10-14 08:35:32 -04:00
proposals Merge pull request #34753 from ivan4th/fix-misspellings-of-kubernetes 2016-10-14 03:09:01 -07:00
user-guide Add 'kubectl set limit' 2016-10-14 08:35:32 -04:00
yaml/kubectl Remove kubectl namespace command 2016-09-22 15:46:20 +02:00
OWNERS
README.md Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00
api.md Change minion to node 2016-09-28 10:53:30 -07:00
reporting-security-issues.md Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00
roadmap.md Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00
troubleshooting.md Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00
warning.png
whatisk8s.md Update the latestReleaseBranch to release-1.4 in the munger. 2016-09-01 14:40:55 -07:00

README.md

WARNING WARNING WARNING WARNING WARNING

PLEASE NOTE: This document applies to the HEAD of the source tree

If you are using a released version of Kubernetes, you should refer to the docs that go with that version.

The latest release of this document can be found [here](http://releases.k8s.io/release-1.4/docs/README.md).

Documentation for other releases can be found at releases.k8s.io.

Kubernetes Documentation: releases.k8s.io/HEAD

Analytics