Class: Forger::Dotenv
- Inherits:
-
Object
- Object
- Forger::Dotenv
- Defined in:
- lib/forger/dotenv.rb
Class Method Summary collapse
-
.dotenv_files ⇒ Object
-
‘.env` - The Original® - `.env.development`, `.env.test`, `.env.production` - Environment-specific settings.
-
- .load! ⇒ Object
- .root ⇒ Object
Class Method Details
.dotenv_files ⇒ Object
-
‘.env` - The Original®
-
‘.env.development`, `.env.test`, `.env.production` - Environment-specific settings.
-
‘.env.local` - Local overrides. This file is loaded for all environments except `test`.
-
‘.env.development.local`, `.env.test.local`, `.env.production.local` - Local overrides of environment-specific settings.
17 18 19 20 21 22 23 24 |
# File 'lib/forger/dotenv.rb', line 17 def dotenv_files [ root.join(".env.#{Forger.env}.local"), (root.join(".env.local") unless Forger.env == "test"), root.join(".env.#{Forger.env}"), root.join(".env") ].compact end |
.load! ⇒ Object
6 7 8 |
# File 'lib/forger/dotenv.rb', line 6 def load! ::Dotenv.load(*dotenv_files) end |