🚸 Ease of use

Added an example.
This commit is contained in:
perp 2023-08-02 05:04:32 +01:00
parent 5242188ffa
commit b18749b867
5 changed files with 20 additions and 15 deletions

View File

@ -11,9 +11,10 @@ import (
// Delete command
var deleteCmd = &cobra.Command{
Use: "delete",
Short: "Delete an alert",
Args: cobra.MinimumNArgs(1),
Use: "delete",
Short: "Delete an alert",
Example: "delete <id>\ndelete <id-1> <id-2>...",
Args: cobra.MinimumNArgs(1),
Run: func(_ *cobra.Command, args []string) {
utils.CheckColor()

View File

@ -11,9 +11,10 @@ import (
// Info command
var infoCmd = &cobra.Command{
Use: "info",
Short: "Return alert information",
Args: cobra.MinimumNArgs(1),
Use: "info",
Short: "Return alert information",
Example: "info <id>\ninfo <id-1> <id-2>...",
Args: cobra.MinimumNArgs(1),
Run: func(_ *cobra.Command, args []string) {
utils.CheckColor()

View File

@ -11,9 +11,10 @@ import (
// Count command
var countCmd = &cobra.Command{
Use: "count",
Short: "Return number of results for a search",
Args: cobra.MinimumNArgs(1),
Use: "count",
Short: "Return number of results for a search",
Example: "count <query>\ncount <query-1> <query-2>...",
Args: cobra.MinimumNArgs(1),
Run: func(_ *cobra.Command, args []string) {
utils.CheckColor()

View File

@ -11,9 +11,10 @@ import (
// Domain command
var domainCmd = &cobra.Command{
Use: "domain",
Short: "Return domain information",
Args: cobra.MinimumNArgs(1),
Use: "domain",
Short: "Return domain information",
Example: "domain <domain>\ndomain <domain-1> <domain-2>...",
Args: cobra.MinimumNArgs(1),
Run: func(_ *cobra.Command, args []string) {
utils.CheckColor()

View File

@ -11,9 +11,10 @@ import (
// Host command
var hostCmd = &cobra.Command{
Use: "host",
Short: "Return host information",
Args: cobra.MinimumNArgs(1),
Use: "host",
Short: "Return host information",
Example: "host <host>\nhost <host-1> <host-2>...",
Args: cobra.MinimumNArgs(1),
Run: func(_ *cobra.Command, args []string) {
utils.CheckColor()