Skip to content

Commit be516f9

Browse files
authored
chore: unhide multi-organization cli commands (#14693)
* chore: unhide multi-organization cli commands Multi-org is going into GA, unhide cli commands
1 parent 370f0b9 commit be516f9

38 files changed

+725
-7
lines changed

cli/organization.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ func (r *RootCmd) organizations() *serpent.Command {
1818
Use: "organizations [subcommand]",
1919
Short: "Organization related commands",
2020
Aliases: []string{"organization", "org", "orgs"},
21-
Hidden: true, // Hidden until these commands are complete.
2221
Handler: func(inv *serpent.Invocation) error {
2322
return inv.Command.HelpHandler(inv)
2423
},

cli/organizationmanage.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ func (r *RootCmd) createOrganization() *serpent.Command {
1818
cmd := &serpent.Command{
1919
Use: "create <organization name>",
2020
Short: "Create a new organization.",
21-
// This action is currently irreversible, so it's hidden until we have a way to delete organizations.
22-
Hidden: true,
2321
Middleware: serpent.Chain(
2422
r.InitClient(client),
2523
serpent.RequireNArgs(1),

cli/organizationroles.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ func (r *RootCmd) organizationRoles(orgContext *OrganizationContext) *serpent.Co
2424
Handler: func(inv *serpent.Invocation) error {
2525
return inv.Command.HelpHandler(inv)
2626
},
27-
Hidden: true,
2827
Children: []*serpent.Command{
2928
r.showOrganizationRoles(orgContext),
3029
r.editOrganizationRole(orgContext),

cli/testdata/coder_--help.golden

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ SUBCOMMANDS:
3131
netcheck Print network debug information for DERP and STUN
3232
notifications Manage Coder notifications
3333
open Open a workspace
34+
organizations Organization related commands
3435
ping Ping a workspace
3536
port-forward Forward ports from a workspace to the local machine. For
3637
reverse port forwarding, use "coder ssh -R".
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations [flags] [subcommand]
5+
6+
Organization related commands
7+
8+
Aliases: organization, org, orgs
9+
10+
SUBCOMMANDS:
11+
create Create a new organization.
12+
members Manage organization members
13+
roles Manage organization roles.
14+
show Show the organization. Using "selected" will show the selected
15+
organization from the "--org" flag. Using "me" will show all
16+
organizations you are a member of.
17+
18+
OPTIONS:
19+
-O, --org string, $CODER_ORGANIZATION
20+
Select which organization (uuid or name) to use.
21+
22+
———
23+
Run `coder --help` for a list of global options.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations create [flags] <organization name>
5+
6+
Create a new organization.
7+
8+
OPTIONS:
9+
-y, --yes bool
10+
Bypass prompts.
11+
12+
———
13+
Run `coder --help` for a list of global options.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations members
5+
6+
Manage organization members
7+
8+
Aliases: member
9+
10+
SUBCOMMANDS:
11+
add Add a new member to the current organization
12+
edit-roles Edit organization member's roles
13+
list List all organization members
14+
remove Remove a new member to the current organization
15+
16+
———
17+
Run `coder --help` for a list of global options.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations members add <username | user_id>
5+
6+
Add a new member to the current organization
7+
8+
———
9+
Run `coder --help` for a list of global options.
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations members edit-roles <username | user_id> [roles...]
5+
6+
Edit organization member's roles
7+
8+
Aliases: edit-role
9+
10+
———
11+
Run `coder --help` for a list of global options.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
coder v0.0.0-devel
2+
3+
USAGE:
4+
coder organizations members list [flags]
5+
6+
List all organization members
7+
8+
OPTIONS:
9+
-c, --column [username|name|user id|organization id|created at|updated at|organization roles] (default: username,organization roles)
10+
Columns to display in table output.
11+
12+
-o, --output table|json (default: table)
13+
Output format.
14+
15+
———
16+
Run `coder --help` for a list of global options.

0 commit comments

Comments
 (0)