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

feat: ignore variables with targetValue nil #72

Merged
merged 1 commit into from
Aug 15, 2023

Conversation

lukasjarosch
Copy link
Owner

The targetValue of variables only evaluates to nil if their actual value is undefined.
This case might occur if one defines an inventory value which uses bash / environment variables, which
ook like skipper variables, but actually aren't.

If in the inventory you have

myclass:
  test: |
    echo "${MY_ENV_VARIABLE}" 

Then ${MY_ENV_VARIABLE} would be treated as skipper variable, but without a targetValue, hence it would be
replaced with nil. This PR changes the default behaviour so that these variables are not replaced at all.

@lukasjarosch lukasjarosch merged commit 9b5321a into main Aug 15, 2023
8 of 14 checks passed
@lukasjarosch lukasjarosch deleted the feat/undefined-variable-handling branch August 15, 2023 06:53
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.

None yet

1 participant