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

Support for suffix with anything-but filtering. #66

Closed
ryan-neff opened this issue Jan 23, 2023 · 5 comments
Closed

Support for suffix with anything-but filtering. #66

ryan-neff opened this issue Jan 23, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@ryan-neff
Copy link

What is your idea?

the prefix comparison key can currently be used in conjunction with anything-but like so:

"state": [ { "anything-but": { "prefix": "init" } } ]

This feature request is simply to have this same support, but for the recently released suffix key.

Example:

"arn": [ { "anything-but": { "suffix": "ServiceRole" } } ]

Would you be willing to make the change?

Yes, but this would be my first contribution to the project.

@ryan-neff ryan-neff added the enhancement New feature or request label Jan 23, 2023
@baldawar
Copy link
Collaborator

This makes sense. If suffix isn't supported today, its likely due to an error (probably a missed entry within an configuration). Along with the change, I would recommend to also add a unit test.

@baldawar
Copy link
Collaborator

baldawar commented Jan 24, 2023

Here's an example of how prefix is configured w anything-but in today.

if (!Constants.PREFIX_MATCH.equals(anythingButObjectOp)) {

@schenksj
Copy link
Contributor

I need this too! I'll go ahead and submit the PR.

@schenksj
Copy link
Contributor

This was addressed by #76 @ryan-neff are we good to close the issue?

@ryan-neff
Copy link
Author

Yes. #76 handled this issue request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants