Set Global Environment Variables in Visual Studio Code

Viewed 423

I am trying to set a variable that will be accessible in as many parts of vscode as possible, for example a VERSION variable that is needed in all sorts of places (terminal, tasks, in the code itself). But I have been unable to do this in a satisfactory way. So far I have tried using an .env file with the vscode Python extension. Variables in these files are unavailable in the terminal when executing tasks.

Am I missing something? Is there no way to set an environment variable that is globally accessible?

0 Answers
Related