Skip to content
a tiny .env wrapper
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
LICENSE
README.md
env.go
go.mod
go.sum

README.md

ENV - a tiny .env wrapper

this is probably not much to use to anybody else but feel free to do whatever you want with it

Notes:

  • .env file is automatically loaded, if there is no .env file this wrapper does not care - no error is thrown
  • APP_ENV must be set to the apps current environment (development/staging/production, ...)
  • get environment variables with Get(key) and GetDefault(key, default)
  • check if production with IsProduction() or development with IsDevelopment()
You can’t perform that action at this time.