I've just set a couple of variables in Windows 10 using the control panel.
Variable: TWILIO_ACCOUNT_SIDVariable Value: my_account_sid
Variable: TWILIO_AUTH_TOKENVariable Value: my_twilio_auth_token
I do refreshenv in powershell so I can see the new values.
But when I do:
Write-Output "$TWILIO_ACCOUNT_SID"
Write-Output "$TWILIO_ACCOUNT_SID"I just get blank lines instead of the values. What am I doing wrong?
1 Answer
In Powershell you can use the ENV:VariableName drive to call environment variables.
Example:
Get-ChildItem ENV:systemroot
Name Value
---- -----
SystemRoot C:\WINDOWSIn your case you can call it as Write-Output "ENV:TWILIO_ACCOUNT_SID"