Sha256: d6e30062f39ef611222472421ed030b3f77bcfff931ad08e24a3695b045337f3
Contents?: true
Size: 605 Bytes
Versions: 5
Compression:
Stored size: 605 Bytes
Contents
require 'ostruct' module Suhyo # Get/set Suhyo's config values. This method can be used in several ways: # # 1. To get config values: # puts Suhyo.config.access_denied_url # 2. To set config values: # Suhyo.config.access_denied_url = 'http://test.host/login' # 3. To set config values in block form: # Suhyo.config do |config| # config.access_denied_url = 'http://test.host/login' # end def self.config @config ||= OpenStruct.new # Set defaults here @config.access_denied_url ||= 'http://test.host/login' # End of defaults yield @config if block_given? @config end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
suhyo-0.0.6 | lib/suhyo/config.rb |
suhyo-0.0.5 | lib/suhyo/config.rb |
suhyo-0.0.3 | lib/suhyo/config.rb |
suhyo-0.0.2 | lib/suhyo/config.rb |
suhyo-0.0.1 | lib/suhyo/config.rb |