class TorrentRSS::Config
Attributes
config_file[RW]
Public Class Methods
config_data()
click to toggle source
# File lib/torrent_rss/config.rb, line 15 def config_data @config_data ||= read_config end
directory()
click to toggle source
# File lib/torrent_rss/config.rb, line 7 def directory config_data['directory'] end
feeds()
click to toggle source
# File lib/torrent_rss/config.rb, line 11 def feeds config_data['feeds'] end
read_config()
click to toggle source
# File lib/torrent_rss/config.rb, line 19 def read_config if File.exists? config_file TOML.load_file config_file else {} end end