Skip to content

Instantly share code, notes, and snippets.

@jeroenvervaeke
Forked from mihow/load_dotenv.sh
Created February 17, 2022 08:47
Show Gist options
  • Save jeroenvervaeke/de00db553e61e0ef43c0c0e24d36d729 to your computer and use it in GitHub Desktop.
Save jeroenvervaeke/de00db553e61e0ef43c0c0e24d36d729 to your computer and use it in GitHub Desktop.
Load environment variables from dotenv / .env file in Bash
if [ ! -f .env ]
then
export $(cat .env | xargs)
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment