bincache 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.3
1
+ 0.0.4
data/bincache.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{bincache}
8
- s.version = "0.0.3"
8
+ s.version = "0.0.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Martin Rhoads"]
data/lib/bincache.rb CHANGED
@@ -7,22 +7,19 @@ require 'right_aws'
7
7
  class BinCache
8
8
 
9
9
  def initialize()
10
- @bucket = 'devs-us-west'
11
- @prefix = 'martin/bincache/'
12
10
  @download_dir = '/tmp'
13
11
 
14
- print_and_exit "s3 keys not set. Please set S3_ACCESS_KEY and S3_SECRET_KEY" unless ENV['S3_ACCESS_KEY'] && ENV['S3_SECRET_KEY']
12
+ print_and_exit "s3 keys not set. Please set S3_BUCKET and S3_PREFIX" unless ENV['S3_BUCKET'] && ENV['S3_PREFIX']
13
+ @bucket = ENV['S3_BUCKET']
14
+ @prefix = ENV['S3_PREFIX']
15
+
15
16
 
17
+ print_and_exit "s3 keys not set. Please set S3_ACCESS_KEY and S3_SECRET_KEY" unless ENV['S3_ACCESS_KEY'] && ENV['S3_SECRET_KEY']
16
18
  @right_s3 = RightAws::S3.new(ENV['S3_ACCESS_KEY'],ENV['S3_SECRET_KEY'])
17
19
  @right_s3_bucket = @right_s3.bucket(@bucket)
18
20
  @right_s3_interface = RightAws::S3Interface.new(ENV['S3_ACCESS_KEY'],ENV['S3_SECRET_KEY'])
19
21
  end
20
22
 
21
-
22
- def bincache(script,dir)
23
- script_hash = Digest::MD5.hexdigest(script)
24
- end
25
-
26
23
  def run_series(directory, scripts)
27
24
  ## exit if given bogus input
28
25
  print_and_exit "bogus input in run_series" if directory.nil? || scripts.nil?
@@ -41,7 +38,6 @@ class BinCache
41
38
 
42
39
  ## step this script
43
40
  step(pop,directory,hash)
44
-
45
41
  end
46
42
 
47
43
  def check_for_hash?(hash)
data/scripts/script1 CHANGED
@@ -1,2 +1,3 @@
1
1
  echo "nana" > nana
2
2
  sleep 3
3
+ ##
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bincache
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 23
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 3
10
- version: 0.0.3
9
+ - 4
10
+ version: 0.0.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Martin Rhoads