carvel-dev / carvel-dev/kapp-controller
kctrl package output when wrong command/input should be consistent
- Dominant language
- Go
- Stars
- 323
- Forks
- 127
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 6
Description
**What steps did you take:**
```
kctrl
kctrl helps to manage packages and repositories on your Kubernetes cluster (package, version)
Usage:
kctrl [flags]
kctrl [command]
Package Commands:
package Package (available, install, installed, repository)
Available/Other Commands:
help Help about any command
version Print client version
Flags:
--color Set color output (default true)
--column strings Filter to show only given columns
--debug Include debug output
-h, --help help for kctrl
--json Output as JSON
--kube-api-burst int Set Kubernetes API client burst limit (default 1000)
--kube-api-qps float32 Set Kubernetes API client QPS limit (default 1000)
--kubeconfig string Path to the kubeconfig file ($KCTRL_KUBECONFIG)
--kubeconfig-context string Kubeconfig context override ($KCTRL_KUBECONFIG_CONTEXT)
--kubeconfig-yaml string Kubeconfig contents as YAML ($KCTRL_KUBECONFIG_YAML)
--tty Force TTY-like output (default true)
-v, --version version for kctrl
-y, --yes Assume yes for any prompt
Use "kctrl [command] --help" for more information about a command.
kctrl: Error: Invalid command - see available commands/subcommands above
❯ kctrl package
kctrl: Error: Use one of available subcommands: available, install, installed, repository
❯ kctrl package get
kctrl: Error: Use one of available subcommands: available, install, installed, repository
```
**What happened:**
`kctrl` without any command, prints help for command and output error, but `kctrl package` without any subcommand prints only error, and not help message that will help understand subcommand, flags, etc...
**What did you expect:**
I would expect the help to be provided so that I don't need to fail or have to do an additional explicit `-h` call to understand usage.
**Environment:**
- kapp Controller version (execute `kubectl get deployment -n kapp-controller kapp-controller -o yaml` and the annotation is `kbld.k14s.io/images`): `kctrl version 0.34.0`
- Kubernetes version (use `kubectl version`)
---
Vote on this request
This is an invitation to the community to vote on issues, to help us prioritize our backlog. Use the "smiley face" up to the right of this comment to vote.
👍 "I would like to see this addressed as soon as possible"
👎 "There are other more important things to focus on right now"
We are also happy to receive and review Pull Requests if you want to help working on this issue.
Contributor guide
Assessment
This issue has not been assessed yet.