Skip to content
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Commit 71eec8e

Browse files
committed
Add aliases for repo, org and org list-users
1 parent 0d5c44f commit 71eec8e

3 files changed

Lines changed: 9 additions & 0 deletions

File tree

internals/secrethub/org.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@ func NewOrgCommand(io ui.IO, newClient newClientFunc) *OrgCommand {
2222
// Register registers the command and its sub-commands on the provided Registerer.
2323
func (cmd *OrgCommand) Register(r command.Registerer) {
2424
clause := r.Command("org", "Manage shared organization workspaces.")
25+
clause.Alias("organization")
26+
clause.Alias("organisation")
27+
clause.Alias("orgs")
28+
clause.Alias("organizations")
29+
clause.Alias("organisations")
2530
NewOrgInitCommand(cmd.io, cmd.newClient).Register(clause)
2631
NewOrgInspectCommand(cmd.io, cmd.newClient).Register(clause)
2732
NewOrgInviteCommand(cmd.io, cmd.newClient).Register(clause)

internals/secrethub/org_list_users.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ func NewOrgListUsersCommand(io ui.IO, newClient newClientFunc) *OrgListUsersComm
3131
// Register registers the command, arguments and flags on the provided Registerer.
3232
func (cmd *OrgListUsersCommand) Register(r command.Registerer) {
3333
clause := r.Command("list-users", "List all members of an organization.")
34+
clause.Alias("list-members")
3435
clause.Arg("org-name", "The organization name").Required().SetValue(&cmd.orgName)
3536
registerTimestampFlag(clause).BoolVar(&cmd.useTimestamps)
3637

internals/secrethub/repo.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ func NewRepoCommand(io ui.IO, newClient newClientFunc) *RepoCommand {
2222
// Register registers the command and its sub-commands on the provided Registerer.
2323
func (cmd *RepoCommand) Register(r command.Registerer) {
2424
clause := r.Command("repo", "Manage repositories.")
25+
clause.Alias("repository")
26+
clause.Alias("repos")
27+
clause.Alias("repositories")
2528
NewRepoInitCommand(cmd.io, cmd.newClient).Register(clause)
2629
NewRepoInspectCommand(cmd.io, cmd.newClient).Register(clause)
2730
NewRepoInviteCommand(cmd.io, cmd.newClient).Register(clause)

0 commit comments

Comments
 (0)