cloudsync 2.0.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.0.0
1
+ 2.0.1
data/cloudsync.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{cloudsync}
8
- s.version = "2.0.0"
8
+ s.version = "2.0.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Cory Forsyth"]
12
- s.date = %q{2010-10-13}
12
+ s.date = %q{2010-10-14}
13
13
  s.default_executable = %q{cloudsync}
14
14
  s.description = %q{Sync files between various clouds or sftp servers. Available backends are S3, CloudFiles, and SFTP servers. Can sync, mirror, and prune.}
15
15
  s.email = %q{cory.forsyth@gmail.com}
@@ -28,10 +28,10 @@ module Cloudsync
28
28
  end
29
29
 
30
30
  def mirror!
31
- $LOGGER.info("Mirror from #{from_backend} to #{to_backend} started at #{mirror_start = Time.now}. Dry-run? #{!!dry_run?}")
31
+ $LOGGER.info("[SM]: Mirror from #{from_backend} to #{to_backend} started at #{mirror_start = Time.now}. Dry-run? #{!!dry_run?}")
32
32
  sync!
33
33
  prune!
34
- $LOGGER.info("Mirror from #{from_backend} to #{to_backend} finished at #{Time.now}. Took #{Time.now - mirror_start}s")
34
+ $LOGGER.info("[SM]: Mirror from #{from_backend} to #{to_backend} finished at #{Time.now}. Took #{Time.now - mirror_start}s")
35
35
  end
36
36
 
37
37
  def dry_run?
@@ -72,7 +72,7 @@ module Cloudsync
72
72
  def prune
73
73
  file_stats = {:removed => [], :skipped => []}
74
74
 
75
- $LOGGER.info("Prune from #{from_backend} to #{to_backend} started at #{prune_start = Time.now}. Dry-run? #{!!dry_run?}")
75
+ $LOGGER.info("[SM]: Prune from #{from_backend} to #{to_backend} started at #{prune_start = Time.now}. Dry-run? #{!!dry_run?}")
76
76
 
77
77
  to_backend_files = to_backend.files_to_sync(from_backend.upload_prefix)
78
78
  total_files = to_backend_files.size
@@ -92,11 +92,11 @@ module Cloudsync
92
92
 
93
93
  if decile_complete(index, total_files) != last_decile_complete
94
94
  last_decile_complete = decile_complete(index, total_files)
95
- $LOGGER.info("Prune: Completed #{index} files. #{last_decile_complete * 10}% complete")
95
+ $LOGGER.info("[SM]: Prune: Completed #{index} files. #{last_decile_complete * 10}% complete")
96
96
  end
97
97
  end
98
98
 
99
- $LOGGER.info(["Prune from #{from_backend} to #{to_backend} finished at #{Time.now}, took #{Time.now - prune_start}s.",
99
+ $LOGGER.info(["[SM]: Prune from #{from_backend} to #{to_backend} finished at #{Time.now}, took #{Time.now - prune_start}s.",
100
100
  "Skipped #{file_stats[:skipped].size} files.",
101
101
  "Removed #{file_stats[:removed].size} files"].join(" "))
102
102
  file_stats
@@ -104,7 +104,7 @@ module Cloudsync
104
104
 
105
105
  def sync(mode)
106
106
  file_stats = {:copied => [], :skipped => []}
107
- $LOGGER.info("Sync from #{from_backend} to #{to_backend} started at #{sync_start = Time.now}. Mode: #{mode}. Dry-run? #{!!dry_run?}")
107
+ $LOGGER.info("[SM]: Sync from #{from_backend} to #{to_backend} started at #{sync_start = Time.now}. Mode: #{mode}. Dry-run? #{!!dry_run?}")
108
108
 
109
109
  from_backend_files = from_backend.files_to_sync(to_backend.upload_prefix)
110
110
  total_files = from_backend_files.size
@@ -121,11 +121,11 @@ module Cloudsync
121
121
 
122
122
  if decile_complete(index, total_files) != last_decile_complete
123
123
  last_decile_complete = decile_complete(index, total_files)
124
- $LOGGER.info("Sync from #{from_backend} to #{to_backend}: Completed #{index} files. #{last_decile_complete * 10}% complete")
124
+ $LOGGER.info("[SM]: Sync from #{from_backend} to #{to_backend}: Completed #{index} files. #{last_decile_complete * 10}% complete")
125
125
  end
126
126
  end
127
127
 
128
- $LOGGER.debug(["Sync from #{from_backend} to #{to_backend} finished at #{Time.now}, took #{Time.now - sync_start}s.",
128
+ $LOGGER.info(["[SM]: Sync from #{from_backend} to #{to_backend} finished at #{Time.now}, took #{Time.now - sync_start}s.",
129
129
  "Copied #{file_stats[:copied].size} files.",
130
130
  "Skipped #{file_stats[:skipped].size} files."].join(" "))
131
131
  file_stats
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloudsync
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
4
+ hash: 13
5
5
  prerelease: false
6
6
  segments:
7
7
  - 2
8
8
  - 0
9
- - 0
10
- version: 2.0.0
9
+ - 1
10
+ version: 2.0.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Cory Forsyth
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-10-13 00:00:00 -04:00
18
+ date: 2010-10-14 00:00:00 -04:00
19
19
  default_executable: cloudsync
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency