module StandupMD
The main module for the gem. Provides access to configuration classes.
Constants
- VERSION
-
Full gem version string.
@return [String]
Public Instance Methods
Source
# File lib/standup_md.rb, line 25 def config @config || reset_config end
Method for accessing the configuration.
@return [StandupMD::Config]
Source
# File lib/standup_md.rb, line 50 def config_file_loaded? @config_file_loaded end
Has a config file been loaded?
@return [Boolean]
Source
# File lib/standup_md.rb, line 42 def configure yield config end
Allows for configuration via a block. Useful when making config files.
@example
StandupMD.configure { |s| s.cli.editor = 'mate' }
Source
# File lib/standup_md.rb, line 60 def load_config_file(config_file) ::File.expand_path(config_file).tap do |file| raise "File #{file} does not exist." unless ::File.file?(file) @config_file_loaded = true load file end end
Loads a config file.
@param [String] file
@return [String] file
Source
# File lib/standup_md.rb, line 33 def reset_config @config = StandupMD::Config.new end
Reset all configuration values to their defaults.
@return [StandupMD::Config]