Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions cmd/smd/component/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ import (
func newCmdComponentGet() *cobra.Command {
// componentGetCmd represents the "smd component get" command
var componentGetCmd = &cobra.Command{
Use: "get",
Args: cobra.NoArgs,
Short: "Get all components or component identified by an xname or node ID",
Use: "get",
Aliases: []string{"list"},
Args: cobra.NoArgs,
Short: "Get all components or component identified by an xname or node ID",
Long: `Get all components or component by an xname or node ID.

See ochami-smd(1) for more details.`,
Expand Down
7 changes: 4 additions & 3 deletions cmd/smd/rfe/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@ import (
func newCmdRfeGet() *cobra.Command {
// rfeGetCmd represents the "smd rfe get" command
var rfeGetCmd = &cobra.Command{
Use: "get",
Args: cobra.NoArgs,
Short: "Get all redfish endpoints or some based on filter(s)",
Use: "get",
Aliases: []string{"list"},
Args: cobra.NoArgs,
Short: "Get all redfish endpoints or some based on filter(s)",
Long: `Get all redfish endpoints or some based on filter(s). If no options are passed,
all redfish endpoints are returned. Optionally, options can be passed to limit the redfish
endpoints returned.
Expand Down
4 changes: 2 additions & 2 deletions man/ochami-smd.1.sc
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ Subcommands for this command are as follows:
- _yaml_

*get* [-F _format_] [--nid _nid_] [--xname _xname_]
Get all components or one identified by xname or node ID.
Get all components or one identified by xname or node ID. Note: `list` is an available alias for this command.

@davidallendj davidallendj Jul 23, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@synackd Is this how you want to specify aliases in the man page documentation or do you have another way?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'll want the aliases to be discoverable, so they should be near the top of the command section. I'm thinking we do it like this:

*get* [-F _format_] [--nid _nid_] [--xname _xname_]
	Aliases: *list*

	Get all components or one identified by xname or node ID.

This seems idiomatic with manual pages of some other popular projects I've come across.


If no filter flags are passed, all components are returned. Otherwise, the
component specified by the passed filter flag(s) is returned.
Expand Down Expand Up @@ -534,7 +534,7 @@ Subcommands for this command are as follows:
Do not ask the user to confirm deletion.

*get* [-F _format_] [--fqdn _fqdn_,...] [-i _ip_,...] [-m _mac_,...] [--type _type_,...] [--uuid _uuid_,...] [-x _xname_,...]
Get all Redfish endpoints or filter by various attributes.
Get all Redfish endpoints or filter by various attributes. Note: `list` is an available alias for this command.

If no filter flags are passed, all Redfish endpoints are returned.
Otherwise, only the endpoint(s) matching the specified filter criteria are
Expand Down
Loading