Skip to content

Commit

Permalink
feat: Add examples to --help output for "delete PROJECT ROLE-NAME" (a…
Browse files Browse the repository at this point in the history
…rgoproj#15986)

* feat: Add examples to --help output for delete PROJECT ROLE-NAME

Signed-off-by: Shauryagulati <[email protected]>

---------

Signed-off-by: Shauryagulati <[email protected]>
  • Loading branch information
Shauryagulati authored and tesla59 committed Dec 16, 2023
1 parent 7eb502c commit a4f72b4
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cmd/argocd/commands/project_role.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import (
"github.com/argoproj/argo-cd/v2/util/errors"
"github.com/argoproj/argo-cd/v2/util/io"
"github.com/argoproj/argo-cd/v2/util/jwt"
"github.com/argoproj/argo-cd/v2/util/templates"
)

const (
Expand Down Expand Up @@ -176,6 +177,11 @@ func NewProjectRoleDeleteCommand(clientOpts *argocdclient.ClientOptions) *cobra.
var command = &cobra.Command{
Use: "delete PROJECT ROLE-NAME",
Short: "Delete a project role",
Example: templates.Examples(`
# Delete a project role from the "my-project" project with the name "my-role".
argocd proj role delete my-project my-role
`),

Run: func(c *cobra.Command, args []string) {
ctx := c.Context()

Expand Down
7 changes: 7 additions & 0 deletions docs/user-guide/commands/argocd_proj_role_delete.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ Delete a project role
argocd proj role delete PROJECT ROLE-NAME [flags]
```

### Examples

```
# Delete a project role from the "my-project" project with the name "my-role".
argocd proj role delete my-project my-role
```

### Options

```
Expand Down

0 comments on commit a4f72b4

Please sign in to comment.