In this video, I'll show you how to set PyCharm environment variables three different ways.
The first way of setting PyCharm environment variables is to use the virtual environment. With this approach, you have to edit activate.bat and deactivate.bat. This is my preferred method because it allows you to use the PyCharm terminal for all your Django work instead of running Play or Debug in PyCharm.
The second way of setting environment variables in PyCharm is to use a plugin. A plugin called EnvFile lets you define your environment variables inside it. You name this file "environment.env" (but you could name it anything as long as it ends with a .env extension). You then reference this file in your project configuration.
The third method is to simply use the project configuration's environment variables within PyCharm. This approach still forces you to Run or Run Debug within PyCharm. You won't be able to use the terminal using this method.
Which method do you prefer? Leave your comment below!
Helpful links
https://stackoverflow.com/questions/4...
Смотрите видео How to Set Environment Variables in PyCharm - 3 Different Ways! онлайн, длительностью часов минут секунд в хорошем качестве, которое загружено на канал Jarad Python 19 Май 2019. Делитесь ссылкой на видео в социальных сетях, чтобы ваши подписчики и друзья так же посмотрели это видео. Данный видеоклип посмотрели 30,343 раз и оно понравилось 166 посетителям.