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

Commit

Permalink
Add docs for autocompletion
Browse files Browse the repository at this point in the history
Signed-off-by: knrt10 <kautilya@kinvolk.io>
  • Loading branch information
knrt10 committed Aug 31, 2020
1 parent 9ce9bfa commit af14a88
Show file tree
Hide file tree
Showing 4 changed files with 115 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/cli/lokoctl.md
Expand Up @@ -21,6 +21,7 @@ Manage Lokomotive clusters
### SEE ALSO

* [lokoctl cluster](lokoctl_cluster.md) - Manage a cluster
* [lokoctl completion](lokoctl_completion.md) - Generate autocompletion script for the specified shell
* [lokoctl component](lokoctl_component.md) - Manage components
* [lokoctl health](lokoctl_health.md) - Get the health of a cluster
* [lokoctl version](lokoctl_version.md) - Print version information
Expand Down
33 changes: 33 additions & 0 deletions docs/cli/lokoctl_completion.md
@@ -0,0 +1,33 @@
## lokoctl completion

Generate autocompletion script for the specified shell

### Synopsis


Generate autocompletion script for lokoctl for the specified shell (bash or zsh).


### Options

```
-h, --help help for completion
```

### Options inherited from parent commands

```
--kubeconfig-file string Path to a kubeconfig file. If empty, the following precedence order is used:
1. Cluster asset dir when a lokocfg file is present in the current directory.
2. KUBECONFIG environment variable.
3. ~/.kube/config file.
--lokocfg string Path to lokocfg directory or file (default "./")
--lokocfg-vars string Path to lokocfg.vars file (default "./lokocfg.vars")
```

### SEE ALSO

* [lokoctl](lokoctl.md) - Manage Lokomotive clusters
* [lokoctl completion bash](lokoctl_completion_bash.md) - Generate autocompletion script for bash
* [lokoctl completion zsh](lokoctl_completion_zsh.md) - Generate autocompletion script for zsh

41 changes: 41 additions & 0 deletions docs/cli/lokoctl_completion_bash.md
@@ -0,0 +1,41 @@
## lokoctl completion bash

Generate autocompletion script for bash

### Synopsis


Generate the autocompletion script for lokoctl for the bash shell.

To load completions in your current shell session:
`$ source <(lokoctl completion bash)`

To load completions for every new session, execute once:
Linux: `$ lokoctl completion bash > /etc/bash_completion.d/lokoctl && exec $SHELL`
MacOS: `$ lokoctl completion bash > /usr/local/etc/bash_completion.d/lokoctl && exec $SHELL`

```
lokoctl completion bash
```

### Options

```
-h, --help help for bash
```

### Options inherited from parent commands

```
--kubeconfig-file string Path to a kubeconfig file. If empty, the following precedence order is used:
1. Cluster asset dir when a lokocfg file is present in the current directory.
2. KUBECONFIG environment variable.
3. ~/.kube/config file.
--lokocfg string Path to lokocfg directory or file (default "./")
--lokocfg-vars string Path to lokocfg.vars file (default "./lokocfg.vars")
```

### SEE ALSO

* [lokoctl completion](lokoctl_completion.md) - Generate autocompletion script for the specified shell

40 changes: 40 additions & 0 deletions docs/cli/lokoctl_completion_zsh.md
@@ -0,0 +1,40 @@
## lokoctl completion zsh

Generate autocompletion script for zsh

### Synopsis


Generate the autocompletion script for lokoctl for the zsh shell.

To load completions in your current shell session:
`$ source <(lokoctl completion zsh)`

To load completions for every new session, execute once:
`$ lokoctl completion zsh > "${fpath[1]}/_lokoctl" && exec $SHELL`

```
lokoctl completion zsh
```

### Options

```
-h, --help help for zsh
```

### Options inherited from parent commands

```
--kubeconfig-file string Path to a kubeconfig file. If empty, the following precedence order is used:
1. Cluster asset dir when a lokocfg file is present in the current directory.
2. KUBECONFIG environment variable.
3. ~/.kube/config file.
--lokocfg string Path to lokocfg directory or file (default "./")
--lokocfg-vars string Path to lokocfg.vars file (default "./lokocfg.vars")
```

### SEE ALSO

* [lokoctl completion](lokoctl_completion.md) - Generate autocompletion script for the specified shell

0 comments on commit af14a88

Please sign in to comment.