Sha256: ff3cc6f78f9df2819e0e69cbf6a14f9e25da33d086a58a13b06f53c0df51cab0

Contents?: true

Size: 643 Bytes

Versions: 4

Compression:

Stored size: 643 Bytes

Contents

require 'active_support/configurable'

module HocusPocus
  include ActiveSupport::Configurable
  config_accessor :enable_generator, :enable_editor, :enable_scenario_recorder, :enable_command_line

  # Configures global settings for HocusPocus
  #   HocusPocus.configure do |config|
  #     config.enable_generator = false
  #   end
  def self.configure(&block)
    yield self
  end

  # this is ugly. why can't we pass the default value to config_accessor...?
  configure do |config|
    config.enable_generator = true
    config.enable_editor = true
    config.enable_scenario_recorder = true
    config.enable_command_line = false
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
hocus_pocus-0.4.1 lib/hocus_pocus/config.rb
hocus_pocus-0.4.0 lib/hocus_pocus/config.rb
hocus_pocus-0.3.0 lib/hocus_pocus/config.rb
hocus_pocus-0.2.1 lib/hocus_pocus/config.rb