Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redesign rules command #680

Closed
vanstee opened this issue May 11, 2016 · 0 comments
Closed

Redesign rules command #680

vanstee opened this issue May 11, 2016 · 0 comments
Assignees
Milestone

Comments

@vanstee
Copy link
Member

vanstee commented May 11, 2016

Fixes similar to permissions by swapping long name options for subcommands and positional args.

USAGE

rules create <rule>
rules create <command> <permission>
rules list [-c <command>] [--command <command>]
rules drop <id>
rules drop [-c <command>] [--command <command>]

EXAMPLES

rules create when command is echo:echo must have echo:write
> Created rule "when command is echo:echo must have echo:write"

rules create "when command is echo:echo must have echo:write"
> Created rule "when command is echo:echo must have echo:write"

rules create echo:echo echo:write
> Created rule "when command is echo:echo must have echo:write"

rules list
> ID                                    RULE
  b3022f58-17af-11e6-840b-17a4fe636484  when command is echo:echo must have echo:write
  cc519e9e-17af-11e6-b7d4-33e4b58aa50d  when commnad is test:test must have test:test

rules list -c echo:echo
> ID                                    RULE
  b3022f58-17af-11e6-840b-17a4fe636484  when command is echo:echo must have echo:write

rules drop b3022f58-17af-11e6-840b-17a4fe636484
> Dropped rule "when command is echo:echo must have echo:write"

rules drop -c echo:echo
> Dropped rule "when command is echo:echo must have echo:write"
  Dropped rule "when command is echo:echo must have echo:read"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants