Class: Backup::Syncer::RSync::Local
- Defined in:
- lib/backup/syncer/rsync/local.rb
Constant Summary
Constants included from CLI::Helpers
Instance Attribute Summary
Attributes inherited from Base
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(&block) ⇒ Local
constructor
Instantiates a new RSync::Local Syncer object.
-
#perform! ⇒ Object
Performs the RSync::Local operation debug options: -vhP.
Methods inherited from Base
Methods included from Configuration::Helpers
#clear_defaults!, #load_defaults!
Methods included from CLI::Helpers
#command_name, #raise_if_command_failed!, #run, #utility
Constructor Details
#initialize(&block) ⇒ Local
Instantiates a new RSync::Local Syncer object. Default configuration values and any specified in Backup::Configuration::Syncer::RSync::Local are set from Base. The user’s configuration file is then evaluated to overwrite these values or provide additional configuration.
14 15 16 17 18 |
# File 'lib/backup/syncer/rsync/local.rb', line 14 def initialize(&block) super instance_eval(&block) if block_given? end |
Instance Method Details
#perform! ⇒ Object
Performs the RSync::Local operation debug options: -vhP
23 24 25 26 27 28 29 30 31 32 |
# File 'lib/backup/syncer/rsync/local.rb', line 23 def perform! Logger.( "#{ syncer_name } started syncing the following directories:\n\s\s" + @directories.join("\n\s\s") ) Logger.silent( run("#{ utility(:rsync) } #{ } " + "#{ directories_option } '#{ dest_path }'") ) end |