Module: Smailr
- Defined in:
- lib/smailr.rb,
lib/smailr/cli.rb,
lib/smailr/dkim.rb,
lib/smailr/alias.rb,
lib/smailr/model.rb,
lib/smailr/setup.rb,
lib/smailr/domain.rb,
lib/smailr/mailbox.rb,
lib/smailr/version.rb
Defined Under Namespace
Modules: Model Classes: Alias, Cli, Dkim, Domain, Mailbox, MissingDomain, Setup
Constant Summary collapse
- DB =
Smailr::db_connect
- VERSION =
'0.8.1'
Class Attribute Summary collapse
-
.config ⇒ Object
Returns the value of attribute config.
-
.config_files ⇒ Object
Returns the value of attribute config_files.
-
.contrib_directory ⇒ Object
Returns the value of attribute contrib_directory.
-
.load_config ⇒ Object
Returns the value of attribute load_config.
-
.migrations_directory ⇒ Object
Returns the value of attribute migrations_directory.
Class Method Summary collapse
Class Attribute Details
.config ⇒ Object
Returns the value of attribute config.
25 26 27 |
# File 'lib/smailr.rb', line 25 def config @config end |
.config_files ⇒ Object
Returns the value of attribute config_files.
26 27 28 |
# File 'lib/smailr.rb', line 26 def config_files @config_files end |
.contrib_directory ⇒ Object
Returns the value of attribute contrib_directory.
28 29 30 |
# File 'lib/smailr.rb', line 28 def contrib_directory @contrib_directory end |
.load_config ⇒ Object
Returns the value of attribute load_config.
27 28 29 |
# File 'lib/smailr.rb', line 27 def load_config @load_config end |
.migrations_directory ⇒ Object
Returns the value of attribute migrations_directory.
29 30 31 |
# File 'lib/smailr.rb', line 29 def migrations_directory @migrations_directory end |
Class Method Details
.db_connect ⇒ Object
42 43 44 |
# File 'lib/smailr.rb', line 42 def self.db_connect Sequel.connect(self.config['database']) end |
.logger ⇒ Object
46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/smailr.rb', line 46 def self.logger unless @logger @logger = Logger.new(STDOUT) @logger.level = Logger::Severity::DEBUG @logger.formatter = proc do |severity, datetime, progname, msg| if severity == "ERROR" "ERROR: #{msg}\n" else "#{msg}\n" end end end @logger end |
.logger=(logger) ⇒ Object
61 62 63 |
# File 'lib/smailr.rb', line 61 def self.logger=(logger) @logger = logger end |