add-to-org 2.1.0 → 2.2.0

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: 034fe0176cc56caed011d70738698f669871fdde
4
- data.tar.gz: 1fd64e861818e5c9a92b38aa83c1f04cd460de77
3
+ metadata.gz: 351c099fc7771a5adc6fd806223371fe4d5ab588
4
+ data.tar.gz: 5616531e6f75f524d8e7af3ca68ea2a34d95c664
5
5
  SHA512:
6
- metadata.gz: e3562fbf9bada4165fe1814cdd8100efcdbe3967e8bfcbcccea82397f18152f11891d87c977b5f552061b466366498f54ad4c72c188e5330f3f2987e43c97da1
7
- data.tar.gz: e6c6579c99b78cd57d6c70d1569b0dc82cf98fd5c62ab60b3a7c71f77d466eaf7838c70871f77df3b555c682d4ea52b7efd1948a29e1e5b16f75770c3c34dcd9
6
+ metadata.gz: 96fe29f18f7ca1e94e0c27e24c5fa8096b7ca7d6abc85531cff9ed759c0e12d8c848d1b3e08975ff1245b0b9882d1dfa634f63cb90ea03bdbe8de616d8152209
7
+ data.tar.gz: 5bb857c019684da4da650e9160f556b3df7ad35aa6796b96d2baf81ff707a086dd5b8c0c3232737cf7c01ca5106ed1f263593ad82479a8b0a12a4fd79f013bbe
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.1.0
1
+ 2.2.3
data/README.md CHANGED
@@ -42,7 +42,7 @@ module AddToOrg
42
42
  verified_emails.any? { |email| email[:email] =~ /@github\.com$/}
43
43
  end
44
44
  end
45
- end
45
+ end
46
46
  ```
47
47
 
48
48
  ## Customizing Views
@@ -54,14 +54,14 @@ module AddToOrg
54
54
  class App < Sinatra::Base
55
55
  set :views, "path/to/your/views"
56
56
  end
57
- end
57
+ end
58
58
  ```
59
59
 
60
60
  or by overwriting the `success`, `forbidden`, and `error` methods entirely:
61
61
 
62
62
  ```ruby
63
63
  module AddToOrg
64
- class App < Sinatra::Base
64
+ class App < Sinatra::Base
65
65
  def success(locals={})
66
66
  halt erb :some_template, :locals => locals
67
67
  end
data/add-to-org.gemspec CHANGED
@@ -18,9 +18,9 @@ Gem::Specification.new do |s|
18
18
  s.require_paths = ["lib"]
19
19
  s.add_dependency "warden-github", "~> 1.1"
20
20
  s.add_dependency "sinatra_auth_github", "~> 1.1"
21
- s.add_dependency "octokit", "~> 3.3"
21
+ s.add_dependency "octokit", "~> 4.0"
22
22
  s.add_dependency "rack-ssl-enforcer", "~> 0.2"
23
- s.add_dependency "dotenv", "~> 1.0"
23
+ s.add_dependency "dotenv", "~> 2.0"
24
24
  s.add_dependency "rake", "~> 10.3"
25
25
  s.add_development_dependency "rspec", "~> 3.1"
26
26
  s.add_development_dependency "rack-test", "~> 0.6"
data/lib/add-to-org.rb CHANGED
@@ -58,7 +58,7 @@ module AddToOrg
58
58
  forbidden unless valid?
59
59
 
60
60
  if add
61
- success({ :redirect => "https://github.com#{path}" })
61
+ success({ :redirect => "https://github.com#{path}", :org_id => org_id })
62
62
  else
63
63
  error
64
64
  end
@@ -1,3 +1,3 @@
1
1
  module AddToOrg
2
- VERSION = "2.1.0"
2
+ VERSION = "2.2.0"
3
3
  end
@@ -6,7 +6,7 @@
6
6
  </head>
7
7
  <body>
8
8
  <h1>You're all set</h1>
9
- <p>You should have recieved an email inviting you to join the organization.</p>
9
+ <p class="lead">You simply need to <a href="https://github.com/orgs/<%= @org_id %>/invitation?return_to=<%= ERB::Util.html_escape(redirect) %>">confirm your invitation to join the organization</a> on GitHub.</p>
10
10
  <p>Once confirmed, you will have access to <a href="<%= ERB::Util.html_escape(redirect) %>"><%= ERB::Util.html_escape(redirect) %></a>, the requested URL.</h1>
11
11
  </body>
12
12
  </html>
@@ -82,7 +82,7 @@ describe "logged in user" do
82
82
  get "/"
83
83
  expect(stub).to have_been_requested
84
84
  expect(last_response.status).to eql(200)
85
- expect(last_response.body).to match(/You should have recieved an email inviting you to join the organization/)
85
+ expect(last_response.body).to match(/confirm your invitation to join the organization/)
86
86
  end
87
87
  end
88
88
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: add-to-org
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Balter
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-06 00:00:00.000000000 Z
11
+ date: 2015-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: warden-github
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '3.3'
47
+ version: '4.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '3.3'
54
+ version: '4.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rack-ssl-enforcer
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -72,14 +72,14 @@ dependencies:
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '1.0'
75
+ version: '2.0'
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: '1.0'
82
+ version: '2.0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: rake
85
85
  requirement: !ruby/object:Gem::Requirement
@@ -199,7 +199,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
199
199
  version: '0'
200
200
  requirements: []
201
201
  rubyforge_project:
202
- rubygems_version: 2.2.0
202
+ rubygems_version: 2.4.8
203
203
  signing_key:
204
204
  specification_version: 4
205
205
  summary: A simple Oauth App to automatically add users to an organization