Sha256: b7e48f2f971105f182274fa66203a9d9d24dfc8e8ec63075f1d78b52f98c5110

Contents?: true

Size: 522 Bytes

Versions: 13

Compression:

Stored size: 522 Bytes

Contents

module Backup
  module Syncer
    module RSync
      class Local < Base
        def perform!
          log!(:started)

          create_dest_path!
          run("#{rsync_command} #{paths_to_push} '#{dest_path}'")

          log!(:finished)
        end

        private

        # Expand path, since this is local and shell-quoted.
        def dest_path
          @dest_path ||= File.expand_path(path)
        end

        def create_dest_path!
          FileUtils.mkdir_p dest_path
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 4 rubygems

Version Path
backup-5.0.0.beta.3 lib/backup/syncer/rsync/local.rb
backedup-5.0.0.beta.5 lib/backup/syncer/rsync/local.rb
backedup-5.0.0.beta.4 lib/backup/syncer/rsync/local.rb
backedup-5.0.0.beta.3 lib/backup/syncer/rsync/local.rb
ext_backup-5.0.0.beta.2.1 lib/backup/syncer/rsync/local.rb
ext_backup-5.0.0.beta.2.ext.0.1.2 lib/backup/syncer/rsync/local.rb
ext_backup-5.0.0.beta.2.ext.0.1.1 lib/backup/syncer/rsync/local.rb
ext_backup-5.0.0.beta.2.ext.0.1.0 lib/backup/syncer/rsync/local.rb
backup-5.0.0.beta.2 lib/backup/syncer/rsync/local.rb
backup-5.0.0.beta.1 lib/backup/syncer/rsync/local.rb
backup-bouchard-4.4.4 lib/backup/syncer/rsync/local.rb
backup-bouchard-4.4.2 lib/backup/syncer/rsync/local.rb
backup-bouchard-4.4.1 lib/backup/syncer/rsync/local.rb