Sha256: bab1cd3e2448a3d05ae03daaf5b32d2ee6dbb2f2ea9539a1126bccd56144584f

Contents?: true

Size: 531 Bytes

Versions: 6

Compression:

Stored size: 531 Bytes

Contents

module Crono
  # Crono::Config stores Crono configuration
  class Config
    CRONOTAB  = 'config/cronotab.rb'
    LOGFILE   = 'log/crono.log'
    PIDFILE   = 'tmp/pids/crono.pid'

    attr_accessor :cronotab, :logfile, :pidfile, :daemonize, :environment

    def initialize
      self.cronotab = CRONOTAB
      self.logfile  = LOGFILE
      self.daemonize = false
      self.environment = ENV['RAILS_ENV'] || ENV['RACK_ENV'] || 'development'
    end

    def pidfile
      @pidfile || (daemonize ? PIDFILE : nil)
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
crono-0.9.0 lib/crono/config.rb
crono-0.8.9 lib/crono/config.rb
crono-0.8.9.pre lib/crono/config.rb
crono-0.8.8.pre lib/crono/config.rb
crono-0.8.7.pre lib/crono/config.rb
crono-0.8.6.pre lib/crono/config.rb