Class: RedashBackup
- Inherits:
-
Object
- Object
- RedashBackup
- Defined in:
- lib/redash_backup.rb,
lib/redash_backup/version.rb
Defined Under Namespace
Constant Summary collapse
- VERSION =
"0.3.0"
Instance Method Summary collapse
- #execute(dir = nil) ⇒ Object
-
#initialize(database_url) ⇒ RedashBackup
constructor
A new instance of RedashBackup.
Constructor Details
#initialize(database_url) ⇒ RedashBackup
Returns a new instance of RedashBackup.
6 7 8 |
# File 'lib/redash_backup.rb', line 6 def initialize(database_url) ENV['DATABASE_URL'] = database_url end |
Instance Method Details
#execute(dir = nil) ⇒ Object
10 11 12 13 |
# File 'lib/redash_backup.rb', line 10 def execute(dir = nil) dir ||= './queries' RedashBackup::Base.export!(dir) end |