warden_skeleton_key 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9ff0abb543519b064f407594bc6e7368f7014567
4
- data.tar.gz: ec1318a83f355eda26e905318e4319bc91f8328d
3
+ metadata.gz: 2edae75ec18a1e257e1102d2b1f11d3cfb3d303f
4
+ data.tar.gz: 07df5dcb3f0fc03b0e01222369de4c92f2122924
5
5
  SHA512:
6
- metadata.gz: d0b73af9c2a4f6165e72155e2ed8e19813192ab5282d75103c29aaa616a57d3d904d6a8e9ae3eacf3a23935801fabc610a2ddda7b0da15b6392b8faf2f22928f
7
- data.tar.gz: 8178b09be2d0840cefae0f600d9cc7641e8b852702fc5710d04b959d698900dd34424f43e70b251bf97558d46d843503f5b27ffdaf7962658a1d926502da8d9c
6
+ metadata.gz: cc5106a8f67118cf473075692db9f64a036b3f8bed15f38ec6f6d438decd840a9a9e5dace20188e47c11648bbebd4305f5858c89a5b62ac396d7c4d5b579e83c
7
+ data.tar.gz: f362799cb22db265621996c5c9c485c0ab76d3c5dce51dcb2de86d06c4b33148efbfe40c71d5ad945ec8868f1b188da9740bc830cef0c5f14b60782455435490
data/README.md CHANGED
@@ -1,6 +1,10 @@
1
1
  # WardenSkeletonKey
2
2
 
3
- TODO: Write a gem description
3
+ [![Gem Version](https://badge.fury.io/rb/warden_skeleton_key.svg)](http://badge.fury.io/rb/warden_skeleton_key)
4
+
5
+ WardenSkeletonKey is a Rack middleware to automatically log you into
6
+ your development environment. Saving you seconds and from forgetting
7
+ those testing passwords. Was it "test123"?
4
8
 
5
9
  ## Installation
6
10
 
@@ -14,13 +18,38 @@ And then execute:
14
18
 
15
19
  $ bundle
16
20
 
17
- Or install it yourself as:
21
+ Add the middleware to your Rails development environment:
18
22
 
19
- $ gem install warden_skeleton_key
23
+ ```ruby
24
+ # config/environments/development.rb
25
+
26
+ Application.configure do
27
+ # ...
28
+
29
+ if ENV["SKIP_SKELETON_KEY"].blank?
30
+ config.middleware.use WardenSkeletonKey do
31
+ # Return a user object to log in
32
+ developer_email = `git config user.email`.chomp
33
+ User.find_by email: [developer_email, 'admin@example.com']
34
+ end
35
+ end
36
+ end
37
+ ```
20
38
 
21
39
  ## Usage
22
40
 
23
- TODO: Write usage instructions here
41
+ The block provided to WardenSkeletonKey must return a valid user object.
42
+ How that user is located is up to you because every system is different.
43
+ Above we're using the current user's git email address and falling
44
+ back to the default "admin@example.com".
45
+
46
+ With the above configuration
47
+ it is possible to skip the middleware entirely using ENV variables
48
+ when you want to restore the log in functionality:
49
+
50
+ ```shell
51
+ $ SKIP_SKELETON_KEY=true rails server # skip the middleware
52
+ ```
24
53
 
25
54
  ## Contributing
26
55
 
@@ -1,3 +1,3 @@
1
1
  class WardenSkeletonKey
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
@@ -6,17 +6,19 @@ require 'warden_skeleton_key/version'
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "warden_skeleton_key"
8
8
  spec.version = WardenSkeletonKey::VERSION
9
- spec.authors = ["Richard Caverly", "Charles Maresh"]
10
- spec.email = ["richard.caverly@orm-tech.com", "charles.maresh@orm-tech.com"]
11
- spec.summary = %q{Warden Skeleton Key}
12
- spec.description = %q{Warden Skeleton Key}
13
- spec.homepage = ""
9
+ spec.authors = ["Jason Stumbaugh", "Charles Maresh"]
10
+ spec.email = ["jason.stumbaugh@orm-tech.com", "charles.maresh@orm-tech.com"]
11
+ spec.summary = %q{WardenSkeletonKey is a Rack middleware to automatically log you into your development environment.}
12
+ spec.description = %q{WardenSkeletonKey is a Rack middleware to automatically log you into your development environment. Saving you seconds and from forgetting those testing passwords. Was it "test123"?}
13
+ spec.homepage = "https://github.com/ormtech/warden_skeleton_key"
14
14
 
15
15
  spec.files = `git ls-files -z`.split("\x0")
16
16
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
17
17
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
18
18
  spec.require_paths = ["lib"]
19
19
 
20
+ spec.add_dependency "railties", "< 5.0"
21
+
20
22
  # spec.add_development_dependency "bundler", "~> 1.7"
21
23
  # spec.add_development_dependency "rake", "~> 10.0"
22
24
  end
metadata CHANGED
@@ -1,25 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: warden_skeleton_key
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
- - Richard Caverly
7
+ - Jason Stumbaugh
8
8
  - Charles Maresh
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-10-10 00:00:00.000000000 Z
13
- dependencies: []
14
- description: Warden Skeleton Key
12
+ date: 2017-12-28 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: railties
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "<"
19
+ - !ruby/object:Gem::Version
20
+ version: '5.0'
21
+ type: :runtime
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "<"
26
+ - !ruby/object:Gem::Version
27
+ version: '5.0'
28
+ description: WardenSkeletonKey is a Rack middleware to automatically log you into
29
+ your development environment. Saving you seconds and from forgetting those testing
30
+ passwords. Was it "test123"?
15
31
  email:
16
- - richard.caverly@orm-tech.com
32
+ - jason.stumbaugh@orm-tech.com
17
33
  - charles.maresh@orm-tech.com
18
34
  executables: []
19
35
  extensions: []
20
36
  extra_rdoc_files: []
21
37
  files:
22
- - .gitignore
38
+ - ".gitignore"
23
39
  - Gemfile
24
40
  - LICENSE.txt
25
41
  - README.md
@@ -27,7 +43,7 @@ files:
27
43
  - lib/warden_skeleton_key.rb
28
44
  - lib/warden_skeleton_key/version.rb
29
45
  - warden_skeleton_key.gemspec
30
- homepage: ''
46
+ homepage: https://github.com/ormtech/warden_skeleton_key
31
47
  licenses: []
32
48
  metadata: {}
33
49
  post_install_message:
@@ -36,18 +52,19 @@ require_paths:
36
52
  - lib
37
53
  required_ruby_version: !ruby/object:Gem::Requirement
38
54
  requirements:
39
- - - '>='
55
+ - - ">="
40
56
  - !ruby/object:Gem::Version
41
57
  version: '0'
42
58
  required_rubygems_version: !ruby/object:Gem::Requirement
43
59
  requirements:
44
- - - '>='
60
+ - - ">="
45
61
  - !ruby/object:Gem::Version
46
62
  version: '0'
47
63
  requirements: []
48
64
  rubyforge_project:
49
- rubygems_version: 2.0.14
65
+ rubygems_version: 2.5.2.1
50
66
  signing_key:
51
67
  specification_version: 4
52
- summary: Warden Skeleton Key
68
+ summary: WardenSkeletonKey is a Rack middleware to automatically log you into your
69
+ development environment.
53
70
  test_files: []