forked from LaconicNetwork/kompose
Merge pull request #1808 from martinjirku/1711-help-page
docs(cli): introduce examples in the kompose command
This commit is contained in:
commit
8b3595ec5f
@ -79,6 +79,9 @@ var (
|
||||
var convertCmd = &cobra.Command{
|
||||
Use: "convert",
|
||||
Short: "Convert a Docker Compose file",
|
||||
Example: ` kompose --file compose.yaml convert
|
||||
kompose -f first.yaml -f second.yaml convert
|
||||
kompose --provider openshift --file compose.yaml convert`,
|
||||
PreRun: func(cmd *cobra.Command, args []string) {
|
||||
|
||||
// Check that build-config wasn't passed in with --provider=kubernetes
|
||||
|
||||
10
cmd/root.go
10
cmd/root.go
@ -50,9 +50,13 @@ var (
|
||||
|
||||
// RootCmd root level flags and commands
|
||||
var RootCmd = &cobra.Command{
|
||||
Use: "kompose",
|
||||
Short: "A tool helping Docker Compose users move to Kubernetes",
|
||||
Long: `Kompose is a tool to help users who are familiar with docker-compose move to Kubernetes.`,
|
||||
Use: "kompose",
|
||||
Short: "A tool helping Docker Compose users move to Kubernetes",
|
||||
Long: `Kompose is a tool to help users who are familiar with docker-compose move to Kubernetes.`,
|
||||
Example: ` kompose --file compose.yaml convert
|
||||
kompose -f first.yaml -f second.yaml convert
|
||||
kompose --provider openshift --file compose.yaml convert
|
||||
kompose completion bash`,
|
||||
SilenceErrors: true,
|
||||
// PersistentPreRun will be "inherited" by all children and ran before *every* command unless
|
||||
// the child has overridden the functionality. This functionality was implemented to check / modify
|
||||
|
||||
Loading…
Reference in New Issue
Block a user