Class: Duple::CLI::Structure
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Duple::CLI::Structure
- Includes:
- Helpers
- Defined in:
- lib/duple/cli/structure.rb
Overview
Usage:
duple structure
Options:
-c, [--config=CONFIG] # The location of the config file.
-s, [--source=SOURCE] # The name of the source environment.
-t, [--target=TARGET] # The name of the target environment.
Copies structure from a source to a target database.
Instance Method Summary collapse
Methods included from Helpers
Instance Method Details
#dump_structure ⇒ Object
20 21 22 |
# File 'lib/duple/cli/structure.rb', line 20 def dump_structure postgres.pg_dump('-Fc --no-acl -O -s', structure_file_path, source_db_config) end |
#load_structure ⇒ Object
28 29 30 |
# File 'lib/duple/cli/structure.rb', line 28 def load_structure postgres.pg_restore('-v --no-acl -O -s', structure_file_path, target_db_config) end |
#reset_target ⇒ Object
24 25 26 |
# File 'lib/duple/cli/structure.rb', line 24 def reset_target reset_database(config.target_environment) end |