How to conditionally set env var? #573
Answered
by
philmillman
bestickley
asked this question in
Q&A
-
|
How to conditionally set env var? For example, if $VARLOCK_IS_CI, I want the env var to be set, otherwise I do not. Example: locally results in: but I don't want them to be defined. |
Beta Was this translation helpful? Give feedback.
Answered by
philmillman
Apr 9, 2026
Replies: 2 comments 2 replies
-
|
you can pass |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
bestickley
-
|
Another option: As for marking it optoinal/required - you can also do |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
you can pass
undefinedinstead of "" and it should do what you want.