✅ Read `launchsettings.json` environment variable from a terminal script in Rider
It looks like the only way to get Rider to reload real environment variable values is to restart the IDE. This is a pain when I'm debugging or experimenting with values that change often, so I figure a way around this is to update the 'fake' environment variable in
launchsettings.json
, then run a script in the IDE terminal to read that value and set the real environment variable in the OS (Windows for now). That way I know my app is getting an up to date value from the OS variable.
I'm just stuck on how to read the launchSetting.json
variable from a terminal script (PowerShell).5 Replies