Add option for MM_DATA_DIR env var to define :data_dir default value

This commit is contained in:
Jim Dalton 2016-01-20 21:11:03 -08:00
parent 5586784947
commit 68127003b9

View file

@ -8,7 +8,7 @@ module Middleman
class Data < Extension
attr_reader :data_store
define_setting :data_dir, 'data', 'The directory data files are stored in'
define_setting :data_dir, ENV['MM_DATA_DIR'] || 'data', 'The directory data files are stored in'
# Make the internal `data_store` method available as `app.data`
expose_to_application data: :data_store