clavem 1.1.1 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -9,12 +9,12 @@ source "http://rubygems.org"
9
9
  gemspec
10
10
 
11
11
  # Testing
12
- gem "rspec", "~> 2.12.0"
12
+ gem "rspec", "~> 2.13.0"
13
13
  gem "rake", "~> 10.0.3"
14
14
 
15
15
  # Documentation
16
16
  gem "simplecov", ">= 0.7.1"
17
17
  gem "pry", ">= 0"
18
- gem "yard", ">= 0.8.4"
18
+ gem "yard", ">= 0.8.5"
19
19
  gem "kramdown", ">= 0.14.2"
20
- gem "github-markup", ">= 0.7.5"
20
+ gem "github-markup", ">= 0.7.5"
data/README.md CHANGED
@@ -1,8 +1,9 @@
1
1
  # Introduction
2
2
 
3
- [![Build Status](https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master)](https://travis-ci.org/ShogunPanda/clavem)
3
+ [![Gem Version](https://badge.fury.io/rb/clavem.png)](http://badge.fury.io/rb/clavem)
4
4
  [![Dependency Status](https://gemnasium.com/ShogunPanda/clavem.png?travis)](https://gemnasium.com/ShogunPanda/clavem)
5
- [![Code Climate](https://codeclimate.com/badge.png)](https://codeclimate.com/github/ShogunPanda/clavem)
5
+ [![Build Status](https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master)](http://travis-ci.org/ShogunPanda/clavem)
6
+ [![Code Climate](https://codeclimate.com/github/ShogunPanda/clavem.png)](https://codeclimate.com/github/ShogunPanda/clavem)
6
7
 
7
8
  A local callback server for oAuth web-flow.
8
9
 
@@ -19,7 +20,7 @@ Simply instantiate the authorizer and run the authorize method with the URL:
19
20
  ```
20
21
  require "clavem"
21
22
 
22
- # Initalize your oAuth access.
23
+ # Initialize your oAuth access.
23
24
 
24
25
  authorizer = Clavem::Authorizer.new
25
26
 
@@ -28,7 +29,7 @@ authorizer = Clavem::Authorizer.new
28
29
  url += "?oauth_callback=#{authorizer.callback_url}"
29
30
  authorizer.authorize(url)
30
31
 
31
- if authorizer.status == :succeded then
32
+ if authorizer.status == :succeeded then
32
33
  access_token = authorizer.token
33
34
 
34
35
  # Go on!
data/bin/clavem CHANGED
@@ -9,14 +9,6 @@ require "clavem"
9
9
  require "mamertes"
10
10
 
11
11
  Mamertes.App(name: "Clavem", version: Clavem::Version::STRING, description: "A local callback server for oAuth web-flow.") do
12
- # @param url [String] The URL where to send the user to start authorization.
13
- # @param ip [String] The IP address on which listening for replies. Default is `127.0.0.1`.
14
- # @param port [Fixnum] The port on which listening for replies. Default is `2501`.
15
- # @param command [String|nil] The command to open the URL. `{{URL}}` is replaced with the specified URL. Default is `open "{{URL}}"`.
16
- # @param title [String|nil] The title for response template. Default is `Clavem Authorization`
17
- # @param template [String|nil] Alternative template to show progress in user's browser.
18
- # @param timeout [Fixnum] The amount of seconds to wait for response from the remote endpoint before returning a failure. Default is `0`, which means *disabled*.
19
-
20
12
  option(:url, ["u", "url"], {type: String, help: "The URL where to send the user to start authorization.", meta: "URL", required: true})
21
13
  option(:ip, ["i", "ip"], {type: String, help: "The IP address on which listening for replies. Default is 127.0.0.1.", meta: "IP", default: "127.0.0.1"})
22
14
  option(:port, ["p", "port"], {type: Integer, help: "The port on which listening for replies. Default is `2501`.", meta: "PORT", default: 2501})
data/clavem.gemspec CHANGED
@@ -24,6 +24,6 @@ Gem::Specification.new do |gem|
24
24
 
25
25
  gem.required_ruby_version = ">= 1.9.3"
26
26
 
27
- gem.add_dependency("mamertes", "~> 2.0.4")
27
+ gem.add_dependency("mamertes", "~> 2.1.0")
28
28
  gem.add_dependency("webrick", "~> 1.3.1")
29
29
  end
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Clavem::Authorizer
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -5876,9 +5876,9 @@
5876
5876
  </div>
5877
5877
 
5878
5878
  <div id="footer">
5879
- Generated on Fri Feb 8 19:25:40 2013 by
5879
+ Generated on Fri Mar 1 08:33:21 2013 by
5880
5880
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
5881
- 0.8.4.1 (ruby-1.9.3).
5881
+ 0.8.5.2 (ruby-1.9.3).
5882
5882
  </div>
5883
5883
 
5884
5884
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Exception: Clavem::Exceptions::AuthorizationDenied
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -124,9 +124,9 @@
124
124
  </div>
125
125
 
126
126
  <div id="footer">
127
- Generated on Fri Feb 8 19:25:39 2013 by
127
+ Generated on Fri Mar 1 08:33:20 2013 by
128
128
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
129
- 0.8.4.1 (ruby-1.9.3).
129
+ 0.8.5.2 (ruby-1.9.3).
130
130
  </div>
131
131
 
132
132
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Exception: Clavem::Exceptions::Failure
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -124,9 +124,9 @@
124
124
  </div>
125
125
 
126
126
  <div id="footer">
127
- Generated on Fri Feb 8 19:25:39 2013 by
127
+ Generated on Fri Mar 1 08:33:20 2013 by
128
128
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
129
- 0.8.4.1 (ruby-1.9.3).
129
+ 0.8.5.2 (ruby-1.9.3).
130
130
  </div>
131
131
 
132
132
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Exception: Clavem::Exceptions::Timeout
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -124,9 +124,9 @@
124
124
  </div>
125
125
 
126
126
  <div id="footer">
127
- Generated on Fri Feb 8 19:25:39 2013 by
127
+ Generated on Fri Mar 1 08:33:20 2013 by
128
128
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
129
- 0.8.4.1 (ruby-1.9.3).
129
+ 0.8.5.2 (ruby-1.9.3).
130
130
  </div>
131
131
 
132
132
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Clavem::Exceptions
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -116,9 +116,9 @@
116
116
  </div>
117
117
 
118
118
  <div id="footer">
119
- Generated on Fri Feb 8 19:25:39 2013 by
119
+ Generated on Fri Mar 1 08:33:20 2013 by
120
120
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
121
- 0.8.4.1 (ruby-1.9.3).
121
+ 0.8.5.2 (ruby-1.9.3).
122
122
  </div>
123
123
 
124
124
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Clavem::Version
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -134,7 +134,7 @@
134
134
 
135
135
  </div>
136
136
  </dt>
137
- <dd><pre class="code"><span class='int'>1</span></pre></dd>
137
+ <dd><pre class="code"><span class='int'>2</span></pre></dd>
138
138
 
139
139
  <dt id="PATCH-constant" class="">PATCH =
140
140
  <div class="docstring">
@@ -149,7 +149,7 @@
149
149
 
150
150
  </div>
151
151
  </dt>
152
- <dd><pre class="code"><span class='int'>1</span></pre></dd>
152
+ <dd><pre class="code"><span class='int'>0</span></pre></dd>
153
153
 
154
154
  <dt id="STRING-constant" class="">STRING =
155
155
  <div class="docstring">
@@ -180,9 +180,9 @@
180
180
  </div>
181
181
 
182
182
  <div id="footer">
183
- Generated on Fri Feb 8 19:25:39 2013 by
183
+ Generated on Fri Mar 1 08:33:20 2013 by
184
184
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
185
- 0.8.4.1 (ruby-1.9.3).
185
+ 0.8.5.2 (ruby-1.9.3).
186
186
  </div>
187
187
 
188
188
  </body>
data/doc/Clavem.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Clavem
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -120,9 +120,9 @@
120
120
  </div>
121
121
 
122
122
  <div id="footer">
123
- Generated on Fri Feb 8 19:25:39 2013 by
123
+ Generated on Fri Mar 1 08:33:20 2013 by
124
124
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
125
- 0.8.4.1 (ruby-1.9.3).
125
+ 0.8.5.2 (ruby-1.9.3).
126
126
  </div>
127
127
 
128
128
  </body>
data/doc/_index.html CHANGED
@@ -4,7 +4,7 @@
4
4
  <head>
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>
7
- Documentation by YARD 0.8.4.1
7
+ Documentation by YARD 0.8.5.2
8
8
 
9
9
  </title>
10
10
 
@@ -56,7 +56,7 @@
56
56
 
57
57
  <iframe id="search_frame"></iframe>
58
58
 
59
- <div id="content"><h1 class="noborder title">Documentation by YARD 0.8.4.1</h1>
59
+ <div id="content"><h1 class="noborder title">Documentation by YARD 0.8.5.2</h1>
60
60
  <div id="listing">
61
61
  <h1 class="alphaindex">Alphabetic Index</h1>
62
62
 
@@ -183,9 +183,9 @@
183
183
  </div>
184
184
 
185
185
  <div id="footer">
186
- Generated on Fri Feb 8 19:25:39 2013 by
186
+ Generated on Fri Mar 1 08:33:20 2013 by
187
187
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
188
- 0.8.4.1 (ruby-1.9.3).
188
+ 0.8.5.2 (ruby-1.9.3).
189
189
  </div>
190
190
 
191
191
  </body>
data/doc/css/style.css CHANGED
@@ -27,6 +27,16 @@ h2 small { font-weight: normal; font-size: 0.7em; display: block; float: right;
27
27
  .rdoc-term { padding-right: 25px; font-weight: bold; }
28
28
  .rdoc-list p { margin: 0; padding: 0; margin-bottom: 4px; }
29
29
 
30
+ /* style for <table> */
31
+ #filecontents table, .docstring table { border-collapse: collapse; }
32
+ #filecontents table th, #filecontents table td,
33
+ .docstring table th, .docstring table td { border: 1px solid #ccc; padding: 8px; padding-right: 17px; }
34
+ #filecontents table tr:nth-child(odd),
35
+ .docstring table tr:nth-child(odd) { background: #eee; }
36
+ #filecontents table tr:nth-child(even),
37
+ .docstring table tr:nth-child(even) { background: #fff; }
38
+ #filecontents table th, .docstring table th { background: #fff; }
39
+
30
40
  /* style for <ul> */
31
41
  #filecontents li > p, .docstring li > p { margin: 0px; }
32
42
  #filecontents ul, .docstring ul { padding-left: 20px; }
data/doc/file.README.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  File: README
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -63,9 +63,10 @@
63
63
 
64
64
  <div id="content"><div id='filecontents'><h1 id="introduction">Introduction</h1>
65
65
 
66
- <p><a href="https://travis-ci.org/ShogunPanda/clavem"><img src="https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master" alt="Build Status" /></a>
66
+ <p><a href="http://badge.fury.io/rb/clavem"><img src="https://badge.fury.io/rb/clavem.png" alt="Gem Version" /></a>
67
67
  <a href="https://gemnasium.com/ShogunPanda/clavem"><img src="https://gemnasium.com/ShogunPanda/clavem.png?travis" alt="Dependency Status" /></a>
68
- <a href="https://codeclimate.com/github/ShogunPanda/clavem"><img src="https://codeclimate.com/badge.png" alt="Code Climate" /></a></p>
68
+ <a href="http://travis-ci.org/ShogunPanda/clavem"><img src="https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master" alt="Build Status" /></a>
69
+ <a href="https://codeclimate.com/github/ShogunPanda/clavem"><img src="https://codeclimate.com/github/ShogunPanda/clavem.png" alt="Code Climate" /></a></p>
69
70
 
70
71
  <p>A local callback server for oAuth web-flow.</p>
71
72
 
@@ -82,7 +83,7 @@
82
83
  <p>```
83
84
  require &#8220;clavem&#8221;</p>
84
85
 
85
- <h1 id="initalize-your-oauth-access">Initalize your oAuth access.</h1>
86
+ <h1 id="initialize-your-oauth-access">Initialize your oAuth access.</h1>
86
87
 
87
88
  <p>authorizer = Clavem::Authorizer.new</p>
88
89
 
@@ -91,7 +92,7 @@ require &#8220;clavem&#8221;</p>
91
92
  <p>url += &#8220;?oauth_callback=#authorizerauthorizer.callback_url&#8221;
92
93
  authorizer.authorize(url)</p>
93
94
 
94
- <p>if authorizer.status == :succeded then
95
+ <p>if authorizer.status == :succeeded then
95
96
  access_token = authorizer.token</p>
96
97
 
97
98
  <p># Go on!
@@ -124,9 +125,9 @@ end
124
125
  </div></div>
125
126
 
126
127
  <div id="footer">
127
- Generated on Fri Feb 8 19:25:39 2013 by
128
+ Generated on Fri Mar 1 08:33:20 2013 by
128
129
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
129
- 0.8.4.1 (ruby-1.9.3).
130
+ 0.8.5.2 (ruby-1.9.3).
130
131
  </div>
131
132
 
132
133
  </body>
data/doc/frames.html CHANGED
@@ -4,7 +4,7 @@
4
4
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5
5
  <head>
6
6
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
7
- <title>Documentation by YARD 0.8.4.1</title>
7
+ <title>Documentation by YARD 0.8.5.2</title>
8
8
  </head>
9
9
  <script type="text/javascript" charset="utf-8">
10
10
  window.onload = function() {
data/doc/index.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  File: README
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -63,9 +63,10 @@
63
63
 
64
64
  <div id="content"><div id='filecontents'><h1 id="introduction">Introduction</h1>
65
65
 
66
- <p><a href="https://travis-ci.org/ShogunPanda/clavem"><img src="https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master" alt="Build Status" /></a>
66
+ <p><a href="http://badge.fury.io/rb/clavem"><img src="https://badge.fury.io/rb/clavem.png" alt="Gem Version" /></a>
67
67
  <a href="https://gemnasium.com/ShogunPanda/clavem"><img src="https://gemnasium.com/ShogunPanda/clavem.png?travis" alt="Dependency Status" /></a>
68
- <a href="https://codeclimate.com/github/ShogunPanda/clavem"><img src="https://codeclimate.com/badge.png" alt="Code Climate" /></a></p>
68
+ <a href="http://travis-ci.org/ShogunPanda/clavem"><img src="https://secure.travis-ci.org/ShogunPanda/clavem.png?branch=master" alt="Build Status" /></a>
69
+ <a href="https://codeclimate.com/github/ShogunPanda/clavem"><img src="https://codeclimate.com/github/ShogunPanda/clavem.png" alt="Code Climate" /></a></p>
69
70
 
70
71
  <p>A local callback server for oAuth web-flow.</p>
71
72
 
@@ -82,7 +83,7 @@
82
83
  <p>```
83
84
  require &#8220;clavem&#8221;</p>
84
85
 
85
- <h1 id="initalize-your-oauth-access">Initalize your oAuth access.</h1>
86
+ <h1 id="initialize-your-oauth-access">Initialize your oAuth access.</h1>
86
87
 
87
88
  <p>authorizer = Clavem::Authorizer.new</p>
88
89
 
@@ -91,7 +92,7 @@ require &#8220;clavem&#8221;</p>
91
92
  <p>url += &#8220;?oauth_callback=#authorizerauthorizer.callback_url&#8221;
92
93
  authorizer.authorize(url)</p>
93
94
 
94
- <p>if authorizer.status == :succeded then
95
+ <p>if authorizer.status == :succeeded then
95
96
  access_token = authorizer.token</p>
96
97
 
97
98
  <p># Go on!
@@ -124,9 +125,9 @@ end
124
125
  </div></div>
125
126
 
126
127
  <div id="footer">
127
- Generated on Fri Feb 8 19:25:39 2013 by
128
+ Generated on Fri Mar 1 08:33:20 2013 by
128
129
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
129
- 0.8.4.1 (ruby-1.9.3).
130
+ 0.8.5.2 (ruby-1.9.3).
130
131
  </div>
131
132
 
132
133
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Top Level Namespace
8
8
 
9
- &mdash; Documentation by YARD 0.8.4.1
9
+ &mdash; Documentation by YARD 0.8.5.2
10
10
 
11
11
  </title>
12
12
 
@@ -103,9 +103,9 @@
103
103
  </div>
104
104
 
105
105
  <div id="footer">
106
- Generated on Fri Feb 8 19:25:39 2013 by
106
+ Generated on Fri Mar 1 08:33:20 2013 by
107
107
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
108
- 0.8.4.1 (ruby-1.9.3).
108
+ 0.8.5.2 (ruby-1.9.3).
109
109
  </div>
110
110
 
111
111
  </body>
@@ -13,10 +13,10 @@ module Clavem
13
13
  MAJOR = 1
14
14
 
15
15
  # The minor version.
16
- MINOR = 1
16
+ MINOR = 2
17
17
 
18
18
  # The patch version.
19
- PATCH = 1
19
+ PATCH = 0
20
20
 
21
21
  # The current version of clavem.
22
22
  STRING = [MAJOR, MINOR, PATCH].compact.join(".")
data/locales/en.yml CHANGED
@@ -11,6 +11,6 @@
11
11
  response_failure: "Cannot handle response: %1"
12
12
  open_failure: "Cannot open URL %1: %2"
13
13
  template:
14
- header_success: "Authentication succeded!"
14
+ header_success: "Authentication succeeded!"
15
15
  header_failure: "Authentication failed!"
16
16
  close_message: "This window should close immediately. Alternatively you can close it by <a href=\"javascript:close_window();\">clicking here</a>."
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: clavem
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.2.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-02-09 00:00:00.000000000 Z
12
+ date: 2013-03-01 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: mamertes
@@ -18,7 +18,7 @@ dependencies:
18
18
  requirements:
19
19
  - - ~>
20
20
  - !ruby/object:Gem::Version
21
- version: 2.0.4
21
+ version: 2.1.0
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - ~>
28
28
  - !ruby/object:Gem::Version
29
- version: 2.0.4
29
+ version: 2.1.0
30
30
  - !ruby/object:Gem::Dependency
31
31
  name: webrick
32
32
  requirement: !ruby/object:Gem::Requirement
@@ -112,7 +112,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
112
112
  version: '0'
113
113
  segments:
114
114
  - 0
115
- hash: -589171599458334454
115
+ hash: 4312469009077191608
116
116
  requirements: []
117
117
  rubyforge_project: clavem
118
118
  rubygems_version: 1.8.25