Class: Mighost::Configuration
- Inherits:
-
Object
- Object
- Mighost::Configuration
- Defined in:
- lib/mighost/configuration.rb
Instance Attribute Summary collapse
-
#auto_capture ⇒ Object
Auto-capture migrations on db:migrate.
-
#dismiss_old_threshold ⇒ Object
Threshold for suggesting dismissal of old unrecoverable migrations.
-
#enabled ⇒ Object
Enabled environments (disabled in production by default).
-
#storage_path ⇒ Object
Path to SQLite file (relative to Rails.root).
-
#store_git_metadata ⇒ Object
Store git metadata (branch, SHA).
Instance Method Summary collapse
- #enabled? ⇒ Boolean
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
24 25 26 27 28 29 30 |
# File 'lib/mighost/configuration.rb', line 24 def initialize @storage_path = ".mighost.sqlite3" @auto_capture = true @store_git_metadata = true @enabled = true @dismiss_old_threshold = 6.months end |
Instance Attribute Details
#auto_capture ⇒ Object
Auto-capture migrations on db:migrate
13 14 15 |
# File 'lib/mighost/configuration.rb', line 13 def auto_capture @auto_capture end |
#dismiss_old_threshold ⇒ Object
Threshold for suggesting dismissal of old unrecoverable migrations
22 23 24 |
# File 'lib/mighost/configuration.rb', line 22 def dismiss_old_threshold @dismiss_old_threshold end |
#enabled ⇒ Object
Enabled environments (disabled in production by default)
19 20 21 |
# File 'lib/mighost/configuration.rb', line 19 def enabled @enabled end |
#storage_path ⇒ Object
Path to SQLite file (relative to Rails.root)
10 11 12 |
# File 'lib/mighost/configuration.rb', line 10 def storage_path @storage_path end |
#store_git_metadata ⇒ Object
Store git metadata (branch, SHA)
16 17 18 |
# File 'lib/mighost/configuration.rb', line 16 def @store_git_metadata end |
Instance Method Details
#enabled? ⇒ Boolean
32 33 34 |
# File 'lib/mighost/configuration.rb', line 32 def enabled? @enabled end |