diff --git a/cli/testdata/coder_users_--help.golden b/cli/testdata/coder_users_--help.golden index 585588cbc6e18..949dc97c3b8d2 100644 --- a/cli/testdata/coder_users_--help.golden +++ b/cli/testdata/coder_users_--help.golden @@ -10,10 +10,10 @@ USAGE: SUBCOMMANDS: activate Update a user's status to 'active'. Active users can fully interact with the platform - create + create Create a new user. delete Delete a user by username or user_id. edit-roles Edit a user's roles by username or id - list + list Prints the list of users. show Show a single user. Use 'me' to indicate the currently authenticated user. suspend Update a user's status to 'suspended'. A suspended user cannot diff --git a/cli/testdata/coder_users_create_--help.golden b/cli/testdata/coder_users_create_--help.golden index 5f57485b52f3c..04f976ab6843c 100644 --- a/cli/testdata/coder_users_create_--help.golden +++ b/cli/testdata/coder_users_create_--help.golden @@ -3,6 +3,8 @@ coder v0.0.0-devel USAGE: coder users create [flags] + Create a new user. + OPTIONS: -O, --org string, $CODER_ORGANIZATION Select which organization (uuid or name) to use. diff --git a/cli/testdata/coder_users_list_--help.golden b/cli/testdata/coder_users_list_--help.golden index 563ad76e1dc72..22c1fe172faf5 100644 --- a/cli/testdata/coder_users_list_--help.golden +++ b/cli/testdata/coder_users_list_--help.golden @@ -3,6 +3,8 @@ coder v0.0.0-devel USAGE: coder users list [flags] + Prints the list of users. + Aliases: ls OPTIONS: diff --git a/cli/usercreate.go b/cli/usercreate.go index f73a3165ee908..643e3554650e5 100644 --- a/cli/usercreate.go +++ b/cli/usercreate.go @@ -28,7 +28,8 @@ func (r *RootCmd) userCreate() *serpent.Command { ) client := new(codersdk.Client) cmd := &serpent.Command{ - Use: "create", + Use: "create", + Short: "Create a new user.", Middleware: serpent.Chain( serpent.RequireNArgs(0), r.InitClient(client), diff --git a/cli/userlist.go b/cli/userlist.go index 48f27f83119a4..e24281ad76d68 100644 --- a/cli/userlist.go +++ b/cli/userlist.go @@ -23,6 +23,7 @@ func (r *RootCmd) userList() *serpent.Command { cmd := &serpent.Command{ Use: "list", + Short: "Prints the list of users.", Aliases: []string{"ls"}, Middleware: serpent.Chain( serpent.RequireNArgs(0), diff --git a/docs/admin/users/index.md b/docs/admin/users/index.md index af26f4bb62a2b..b7d98b919734c 100644 --- a/docs/admin/users/index.md +++ b/docs/admin/users/index.md @@ -206,3 +206,42 @@ The following filters are supported: - `created_before` and `created_after` - The time a user was created. Uses the RFC3339Nano format. - `login_type` - Represents the login type of the user. Refer to the [LoginType documentation](https://pkg.go.dev/github.com/coder/coder/v2/codersdk#LoginType) for a list of supported values + +## Retrieve your list of Coder users + +
create
](./users_create.md) | |
-| [list
](./users_list.md) | |
+| [create
](./users_create.md) | Create a new user. |
+| [list
](./users_list.md) | Prints the list of users. |
| [show
](./users_show.md) | Show a single user. Use 'me' to indicate the currently authenticated user. |
| [delete
](./users_delete.md) | Delete a user by username or user_id. |
| [edit-roles
](./users_edit-roles.md) | Edit a user's roles by username or id |
diff --git a/docs/reference/cli/users_create.md b/docs/reference/cli/users_create.md
index 61768ebfdbbf8..646eb55ffb5ba 100644
--- a/docs/reference/cli/users_create.md
+++ b/docs/reference/cli/users_create.md
@@ -1,6 +1,8 @@
# users create
+Create a new user.
+
## Usage
```console
diff --git a/docs/reference/cli/users_list.md b/docs/reference/cli/users_list.md
index 9293ff13c923c..93122e7741072 100644
--- a/docs/reference/cli/users_list.md
+++ b/docs/reference/cli/users_list.md
@@ -1,6 +1,8 @@
# users list
+Prints the list of users.
+
Aliases:
* ls