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

Make leading/trailing spaces optional in templating #792

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

agershman
Copy link

@agershman agershman commented Nov 5, 2024

What changed?

Allow templating in granted config file to contain lead/trailing spaces or not at all.

Why?

The usage of templating in granted config files is more forgiving if the author doesn't have spaces in their go templating syntax. Without this it's unclear why template syntax is left un-rendered in the AWS config file.

How did you test it?

Built CLI and tested using a registry containing a test profile config and granted config file:

Test profile config

image

Test granted config

image

Add test registry

image

Observe rendered profiles

image

Potential risks

There shouldn't be risks given that the updated regular expression allows for zero or more spaces, which should be backwards compatible with all existing usages.

Is patch release candidate?

Link to relevant docs PRs

N/A

@agershman agershman force-pushed the gersh/template-spaces-optional branch from 65db951 to 20830b8 Compare November 5, 2024 22:31
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.

1 participant