-
-
Save codeadict/ea9fe4c86628585e0b04c39ce76a2874 to your computer and use it in GitHub Desktop.
Loading .env
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ cat .env | |
| API_KEY=supersecretstuff | |
| $ pipenv run python | |
| Loading .env environment variables… | |
| Python 3.6.3 (default, Oct 4 2017, 06:09:15) | |
| [GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.37)] on darwin | |
| Type "help", "copyright", "credits" or "license" for more information. | |
| >>> import os | |
| >>> os.getenv['API_KEY'] | |
| 'supersecretstuff' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment