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

Custom env variables #50

Merged
merged 2 commits into from
Jan 3, 2023
Merged

Custom env variables #50

merged 2 commits into from
Jan 3, 2023

Conversation

jakobra
Copy link
Contributor

@jakobra jakobra commented Dec 22, 2022

This goes back a few years to #24 and #15. Hopefully we can get this into place now.

Copy link
Member

@nblumhardt nblumhardt left a comment

Choose a reason for hiding this comment

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

Looks great! Just had one minor nitpick/question.


if (string.IsNullOrWhiteSpace(environmentVariableValue))
{
environmentVariableValue = "<Empty>";
Copy link
Member

Choose a reason for hiding this comment

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

Any reason for a placeholder here? It should be fine to create a property with an empty or null value.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not really actually, I guess I was just "tainted" by default value of EnvironmentName (production) and that it can sometimes be nice during debugging to see if your value is picked up or not but for me this is no big question. Codewise it's cleaner to just remove it.

@jakobra jakobra force-pushed the customEnvVariables branch from 0cc353d to 402d17a Compare January 3, 2023 09:17
@nblumhardt nblumhardt merged commit a722b03 into serilog:dev Jan 3, 2023
@nblumhardt
Copy link
Member

Great, thanks! 👍

I'll keep an eye on CI/publishing; a -dev package should be on NuGet soon.

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.

2 participants