Class: TrackList::Environment
- Inherits:
-
Object
- Object
- TrackList::Environment
- Defined in:
- lib/track_list/environment.rb
Instance Method Summary collapse
- #get_config_path ⇒ Object
-
#initialize ⇒ Environment
constructor
A new instance of Environment.
Constructor Details
#initialize ⇒ Environment
Returns a new instance of Environment.
3 4 5 6 7 8 9 |
# File 'lib/track_list/environment.rb', line 3 def initialize if ENV.has_value?("TRACKLIST_CONFIG") @config_path = ENV["TRACKLIST_CONFIG"] else @config_path = Dir.home() + '/.config/track_list/settings.yaml' end end |
Instance Method Details
#get_config_path ⇒ Object
11 12 13 |
# File 'lib/track_list/environment.rb', line 11 def get_config_path @config_path end |