Skip to content

Fixes #288 - adds abbreviated argument flags for power users #293

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

Merged
merged 2 commits into from
Dec 8, 2020

Conversation

kmcquade
Copy link
Collaborator

@kmcquade kmcquade commented Dec 1, 2020

What does this PR do?

Adds abbreviated argument flags, which fixes #288. I had several users request this feature because it would take too long to write the commands.

Here are the new argument options:

policy_sentry write-policy

  • --input-file: -i
  • --mimimize: -m

policy_sentry create-template

  • --output-file: -o
  • --template-type: -t

For the query functions:

  • --service: -s
  • --name: -n
  • --access-level: -a
  • --condition: -c
  • --resource-type: -r
  • --list-arn-types: -l

Note: I opted to not set an abbreviated argument flag for --fmt because the -f flag is usually used for "file". To avoid confusion, I just left it as --fmt

What gif best describes this PR or how it makes you feel?

image

Completion checklist

@kmcquade kmcquade self-assigned this Dec 1, 2020
@kmcquade kmcquade requested a review from reetasingh December 2, 2020 21:59
@reetasingh
Copy link
Contributor

reetasingh commented Dec 3, 2020

@kmcquade you might have to update your fork with latest from upstream/master

@@ -12,21 +12,26 @@

logger = logging.getLogger(__name__)


Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes in this file only relate to spacing. I hit "reformat file" to make the IDE happy

@kmcquade kmcquade merged commit 8cc3f68 into salesforce:master Dec 8, 2020
@kmcquade kmcquade deleted the fix/GH-288-argument-flags branch December 8, 2020 15:59
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

Successfully merging this pull request may close these issues.

Abbreviated argument flags
2 participants