Skip to content

Instantly share code, notes, and snippets.

@csmosx
csmosx / dotenv
Created June 13, 2017 20:57
bash dotenv
#!/bin/bash
# dotenv - run a program in an environment with added vars parsed from a .env file
env $(if [ -f .env ]; then cat .env | grep -v ^# | xargs; fi) $@