Added more documentation and changed param names

This commit is contained in:
David Allen 2024-07-22 14:22:02 -06:00
parent c537e496da
commit eba9dfa1e7
No known key found for this signature in database
GPG key ID: 717C593FF60A2ACC
5 changed files with 46 additions and 59 deletions

View file

@ -11,13 +11,16 @@ import (
"github.com/spf13/cobra"
)
// The `crawl` command walks a collection of Redfish endpoints to collect
// specfic inventory detail. This command only expects host names and does
// not require a scan to be performed beforehand.
var crawlCmd = &cobra.Command{
Use: "crawl [uri]",
Use: "crawl [uri]",
Short: "Crawl a single BMC for inventory information",
Long: "Crawl a single BMC for inventory information\n" +
"\n" +
"Example:\n" +
" magellan crawl https://bmc.example.com",
Short: "Crawl a single BMC for inventory information",
Args: func(cmd *cobra.Command, args []string) error {
// Validate that the only argument is a valid URI
if err := cobra.ExactArgs(1)(cmd, args); err != nil {