vault-tools 0.5.5 → 0.5.6

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/.gitignore CHANGED
@@ -3,7 +3,6 @@
3
3
  .bundle
4
4
  .config
5
5
  .yardoc
6
- Gemfile.lock
7
6
  InstalledFiles
8
7
  _yardoc
9
8
  bin/*
@@ -18,4 +17,4 @@ test/version_tmp
18
17
  tmp
19
18
  test.profile*
20
19
  test/.test.profile*
21
- vendor
20
+ vendor
data/Gemfile.lock ADDED
@@ -0,0 +1,117 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ vault-tools (0.5.6)
5
+ aws-sdk
6
+ fernet (= 2.0.rc2)
7
+ heroku-api
8
+ honeybadger
9
+ rack-ssl-enforcer
10
+ rdoc
11
+ scrolls
12
+ sinatra (~> 1.4.4)
13
+ uuidtools
14
+ yard
15
+
16
+ GEM
17
+ remote: https://rubygems.org/
18
+ specs:
19
+ ansi (1.4.3)
20
+ aws-sdk (1.52.0)
21
+ aws-sdk-v1 (= 1.52.0)
22
+ aws-sdk-v1 (1.52.0)
23
+ json (~> 1.4)
24
+ nokogiri (>= 1.4.4)
25
+ celluloid (0.16.0)
26
+ timers (~> 4.0.0)
27
+ coderay (1.1.0)
28
+ excon (0.39.5)
29
+ fernet (2.0.rc2)
30
+ valcro (= 0.1)
31
+ ffi (1.9.3)
32
+ formatador (0.2.5)
33
+ guard (2.6.1)
34
+ formatador (>= 0.2.4)
35
+ listen (~> 2.7)
36
+ lumberjack (~> 1.0)
37
+ pry (>= 0.9.12)
38
+ thor (>= 0.18.1)
39
+ guard-minitest (2.3.2)
40
+ guard (~> 2.0)
41
+ minitest (>= 3.0)
42
+ heroku-api (0.3.19)
43
+ excon (~> 0.38)
44
+ multi_json (~> 1.8)
45
+ hitimes (1.2.2)
46
+ honeybadger (1.16.4)
47
+ json
48
+ json (1.8.1)
49
+ listen (2.7.9)
50
+ celluloid (>= 0.15.2)
51
+ rb-fsevent (>= 0.9.3)
52
+ rb-inotify (>= 0.9)
53
+ logfmt (0.0.6)
54
+ lumberjack (1.0.9)
55
+ method_source (0.8.2)
56
+ mini_portile (0.6.0)
57
+ minitest (4.7.5)
58
+ multi_json (1.10.1)
59
+ nokogiri (1.6.3.1)
60
+ mini_portile (= 0.6.0)
61
+ pry (0.10.1)
62
+ coderay (~> 1.1.0)
63
+ method_source (~> 0.8.1)
64
+ slop (~> 3.4)
65
+ rack (1.5.2)
66
+ rack-protection (1.5.3)
67
+ rack
68
+ rack-ssl-enforcer (0.2.8)
69
+ rack-test (0.6.2)
70
+ rack (>= 1.0)
71
+ rake (10.1.0)
72
+ rb-fsevent (0.9.4)
73
+ rb-inotify (0.9.5)
74
+ ffi (>= 0.5.0)
75
+ rdoc (4.1.1)
76
+ json (~> 1.4)
77
+ rr (1.1.2)
78
+ scrolls (0.3.8)
79
+ shotgun (0.9)
80
+ rack (>= 1.0)
81
+ sinatra (1.4.5)
82
+ rack (~> 1.4)
83
+ rack-protection (~> 1.4)
84
+ tilt (~> 1.3, >= 1.3.4)
85
+ slop (3.6.0)
86
+ thor (0.19.1)
87
+ tilt (1.4.1)
88
+ timers (4.0.0)
89
+ hitimes
90
+ turn (0.9.7)
91
+ ansi
92
+ minitest (~> 4)
93
+ uuidtools (2.1.5)
94
+ valcro (0.1)
95
+ vault-test-tools (0.3.8)
96
+ guard-minitest
97
+ logfmt
98
+ minitest (~> 4.7.4)
99
+ nokogiri
100
+ rack-test
101
+ rr
102
+ scrolls
103
+ turn
104
+ yard (0.8.7.3)
105
+ yard-sinatra (1.0.0)
106
+ yard (~> 0.7)
107
+
108
+ PLATFORMS
109
+ ruby
110
+
111
+ DEPENDENCIES
112
+ guard-minitest
113
+ rake
114
+ shotgun
115
+ vault-test-tools
116
+ vault-tools!
117
+ yard-sinatra
data/README.md CHANGED
@@ -5,32 +5,56 @@ team to enable faster bootstrapping for Ruby projects.
5
5
 
6
6
  [![Build Status](https://travis-ci.org/heroku/vault-tools.png?branch=master)](https://travis-ci.org/heroku/vault-tools)
7
7
 
8
- ## Setting up a development environment
8
+ ## Installation
9
9
 
10
- Install the dependencies:
10
+ Add this line to your application's Gemfile:
11
11
 
12
- bundle install --binstubs vendor/bin
13
- rbenv rehash
12
+ gem 'vault-tools'
14
13
 
15
- Run the tests:
16
14
 
17
- vendor/bin/t
15
+ ## Usage
18
16
 
19
- Generate the API documentation:
17
+ ### `Vault.setup`
20
18
 
21
- vendor/bin/d
19
+ calling `Vault.setup` will:
22
20
 
21
+ - call `Bundler.require` with the corresponding `RACK_ENV`
22
+ - add `./lib` to the `$LOAD_PATH`
23
+ - set `TZ` to utc as well as `Sequel`'s default timezone
24
+ - overwrite `Time.to_s` to default to ISO8601
25
+ - replace Ruby's default, deprecated `Config` with `Vault::Config`
26
+ - if the `CONFIG_APP` environment variable is defined and this is
27
+ the production environment, it will attempt to use the Heroku API
28
+ to load the config vars from another app into `Vault::Config`
23
29
 
24
- ## Installation
25
30
 
26
- Add this line to your application's Gemfile:
31
+ ### `Vault::Config`
27
32
 
28
- gem 'vault-tools'
33
+ Provides a better way to configure the application than simply pulling
34
+ strings from `ENV`.
29
35
 
36
+ #### defaults
30
37
 
31
- ## Usage
38
+ ```ruby
39
+ Config[:foo]
40
+ # => nil
41
+
42
+ Config.default(:foo, 'bar')
43
+ Config[:foo]
44
+ # => 'bar'
45
+ Config['FOO']
46
+ # => 'bar'
47
+ ```
48
+
49
+ #### type casts
32
50
 
33
- ### Logging
51
+ Returns `nil` when undefined, otherwise casts to indicated type.
52
+
53
+ ```ruby
54
+ Config.int(:max_connections)
55
+ ```
56
+
57
+ ### `Vault::Log`
34
58
 
35
59
  ```ruby
36
60
  Log.time(name, t)
@@ -40,7 +64,9 @@ Add this line to your application's Gemfile:
40
64
  # => "measure=true at=foo"
41
65
  ```
42
66
 
43
- ### Sinatra base class
67
+ ### `Vault::Web`
68
+
69
+ Sinatra base class
44
70
 
45
71
  Includes request logging and health endpoints
46
72
 
@@ -50,6 +76,23 @@ Includes request logging and health endpoints
50
76
  end
51
77
  ```
52
78
 
79
+ ## Setting up a development environment
80
+
81
+ Install the dependencies:
82
+
83
+ bundle install --binstubs vendor/bin
84
+ rbenv rehash
85
+
86
+ Run the tests:
87
+
88
+ vendor/bin/t
89
+
90
+ Generate the API documentation:
91
+
92
+ vendor/bin/d
93
+
94
+
95
+
53
96
  ## Contributing
54
97
 
55
98
  1. Fork it
@@ -6,7 +6,7 @@ require 'vault-tools/s3'
6
6
  namespace :docs do
7
7
  desc "Publish Docs to S3"
8
8
  task :publish do
9
- DOC_BUCKET = "heroku-vault-docs2"
9
+ DOC_BUCKET = "vault-docs.heroku.com"
10
10
  DOC_DIR_NAME = Dir.pwd.split("/").last
11
11
 
12
12
  # Check for s3cmd CLI
@@ -1,3 +1,5 @@
1
+ require 'aws-sdk'
2
+
1
3
  module S3
2
4
  extend self
3
5
 
@@ -1,5 +1,5 @@
1
1
  module Vault
2
2
  module Tools
3
- VERSION = '0.5.5'
3
+ VERSION = '0.5.6'
4
4
  end
5
5
  end
data/test/helper.rb CHANGED
@@ -1,6 +1,5 @@
1
1
  require 'vault-test-tools'
2
2
  require 'vault-tools'
3
- require 'aws-sdk'
4
3
  require 'rr'
5
4
 
6
5
  ENV['RACK_ENV'] = 'test'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vault-tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.5
4
+ version: 0.5.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2014-04-10 00:00:00.000000000 Z
13
+ date: 2014-09-09 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: scrolls
@@ -188,6 +188,7 @@ files:
188
188
  - .travis.yml
189
189
  - .yardopts
190
190
  - Gemfile
191
+ - Gemfile.lock
191
192
  - Guardfile
192
193
  - LICENSE.txt
193
194
  - README.md
@@ -240,7 +241,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
240
241
  version: '0'
241
242
  segments:
242
243
  - 0
243
- hash: 915007437591633538
244
+ hash: 1340020466520949666
244
245
  required_rubygems_version: !ruby/object:Gem::Requirement
245
246
  none: false
246
247
  requirements:
@@ -249,7 +250,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
249
250
  version: '0'
250
251
  segments:
251
252
  - 0
252
- hash: 915007437591633538
253
+ hash: 1340020466520949666
253
254
  requirements: []
254
255
  rubyforge_project:
255
256
  rubygems_version: 1.8.23