Skip to content

Commit 1772b60

Browse files
committed
Updated the help for each command
Signed-off-by: Luxxgit2k4 <[email protected]>
1 parent 37fce34 commit 1772b60

File tree

2 files changed

+17
-15
lines changed

2 files changed

+17
-15
lines changed

cmd/import.go

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,18 @@ import (
2828
)
2929

3030
var importCmd = &cobra.Command{
31-
Use: "import <specificationFile1[:primary],specificationFile2[:primary]>",
32-
Short: "Import API specifications into Microcks",
33-
Args: cobra.ExactArgs(1),
31+
Use: "import <specificationFile1[:primary],specificationFile2[:primary]>",
32+
Short: "Import API artifacts on Microcks server",
33+
Long: `Import API artifacts into Microcks server.
34+
35+
Args:
36+
<specificationFile1[:primary],specificationFile2[:primary]> Exemple: 'specs/my-openapi.yaml:true,specs/my-postmancollection.json:false'
37+
38+
Flags:
39+
--microcksURL Microcks API endpoint (URL to the Microcks server)
40+
--keycloakClientId Keycloak Realm Service Account ClientId
41+
--keycloakClientSecret Keycloak Realm Service Account ClientSecret`,
42+
Args: cobra.ExactArgs(1),
3443
Run: func(cmd *cobra.Command, args []string) {
3544
specificationFiles := args[0]
3645

cmd/root.go

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
/*
2-
Copyright © 2025 NAME HERE <EMAIL ADDRESS>
3-
4-
*/
51
package cmd
62

73
import (
@@ -10,20 +6,17 @@ import (
106

117
"github.com/spf13/cobra"
128
"github.com/spf13/viper"
13-
)
9+
)
1410

1511
var cfgFile string
1612

1713
// rootCmd represents the base command when called without any subcommands
1814
var rootCmd = &cobra.Command{
19-
Use: "microcks-cli",
20-
Short: "A brief description of your application",
21-
Long: `A longer description that spans multiple lines and likely contains
22-
examples and usage of using your application. For example:
15+
Use: "microcks-cli",
16+
Short: "microcks-cli is a CLI for interacting with Microcks server APIs.",
17+
Long: `microcks-cli is a CLI tool to interact with Microcks server APIs.
18+
It allows launching tests and importing API artifacts with minimal dependencies.`,
2319

24-
Cobra is a CLI library for Go that empowers applications.
25-
This application is a tool to generate the needed files
26-
to quickly create a Cobra application.`,
2720
// Uncomment the following line if your bare application
2821
// has an action associated with it:
2922
// Run: func(cmd *cobra.Command, args []string) { },

0 commit comments

Comments
 (0)