encbs 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.2
1
+ 0.1.3
data/bin/encbs CHANGED
@@ -218,7 +218,7 @@ if @config.paths || opts.add?
218
218
  end
219
219
 
220
220
  paths.each do |path|
221
- @backup.create! path, opts.increment?
221
+ @backup.create! path, @config.increment || opts.increment?
222
222
  end
223
223
 
224
224
  puts "Done!".green
data/encbs.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{encbs}
8
- s.version = "0.1.2"
8
+ s.version = "0.1.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Timothy Klim"]
12
- s.date = %q{2011-05-13}
12
+ s.date = %q{2011-05-14}
13
13
  s.default_executable = %q{encbs}
14
14
  s.description = %q{Simple backup system for pushing into cloud}
15
15
  s.email = %q{klimtimothy@gmail.com}
data/lib/backup/jar.rb CHANGED
@@ -19,13 +19,13 @@ module Backup
19
19
  @local_files = {}
20
20
  current_files = hash_local_files
21
21
 
22
- last_timestamp = Jar.jar_versions(@root_path, jar_hash, true).last
22
+ last_timestamp = Jar.jar_versions(@file_item, @root_path, jar_hash, true).last
23
23
 
24
24
  if last_timestamp.nil?
25
25
  puts_fail "First you must create a full backup for #{@local_path.dark_green}"
26
26
  end
27
27
 
28
- last_index = Jar.fetch_index_for(@root_path, jar_hash, last_timestamp)
28
+ last_index = Jar.fetch_index_for(@file_item, @root_path, jar_hash, last_timestamp)
29
29
 
30
30
  current_files.keys.each do |file|
31
31
  @local_files[file] = current_files[file]
@@ -58,6 +58,7 @@ module Backup
58
58
  @local_files.to_yaml
59
59
  )
60
60
 
61
+ @local_files.select! {|k, v| v[:timestamp] == @timestamp}
61
62
  if @file_item.is_a? Backup::FileItem::Cloud
62
63
  pbar = ProgressBar.new(
63
64
  "Uploading",
@@ -84,7 +85,7 @@ module Backup
84
85
  "#{jar_data_path}/#{@file_item.file_hash file}",
85
86
  data
86
87
  )
87
-
88
+
88
89
  pbar.inc
89
90
  end
90
91
  end
data/lib/encbsconfig.rb CHANGED
@@ -7,6 +7,11 @@ class EncbsConfig
7
7
  end
8
8
 
9
9
  def load(path)
10
+ [:bucket, :colorize, :hostname, :increment, :key, :secret,
11
+ :token, :verbose].each {|attr| eval "@#{attr} = nil"}
12
+
13
+ @paths = ""
14
+
10
15
  eval "#{open(path).read}"
11
16
  end
12
17
 
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: encbs
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.1.2
5
+ version: 0.1.3
6
6
  platform: ruby
7
7
  authors:
8
8
  - Timothy Klim
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-05-13 00:00:00 +04:00
13
+ date: 2011-05-14 00:00:00 +04:00
14
14
  default_executable: encbs
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
@@ -128,7 +128,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - ">="
130
130
  - !ruby/object:Gem::Version
131
- hash: -215227041177013415
131
+ hash: -3909970263344363647
132
132
  segments:
133
133
  - 0
134
134
  version: "0"