GoogleReaderApi 0.4.0 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/GoogleReaderApi.gemspec +3 -12
- data/README.mdown +4 -1
- data/VERSION +1 -1
- data/lib/google-reader-api/api.rb +6 -1
- metadata +7 -10
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: aa16f4a423e9b65874387449f2fd75c17b53fc55
|
4
|
+
data.tar.gz: e274487324b81a42b0b2e15debf9dac5f4495c1c
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: db51a3a6969c6d75c49cbd2bb6e412ee11619d9ad35b5b85fd62dfe290bb347ae0f8e46a1ea0cf5e36c509ea2fa19551f746e9e7e22fe1b1e72601aecb49aa4e
|
7
|
+
data.tar.gz: 0540896f7667178770da383cf0048cf4381c5f784ab71688b08830625e16d907ae192dc9eab40ba3537fcd2b037b07fafdb81e79bfab02a5b7849cfec712adfd
|
data/GoogleReaderApi.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "GoogleReaderApi"
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.5.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Toon Willems"]
|
12
|
-
s.date = "
|
12
|
+
s.date = "2013-04-09"
|
13
13
|
s.description = "a google reader api (unofficial) written in ruby"
|
14
14
|
s.email = "willemstoon@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
@@ -33,16 +33,7 @@ Gem::Specification.new do |s|
|
|
33
33
|
]
|
34
34
|
s.homepage = "http://github.com/nudded/GoogleReaderAPI"
|
35
35
|
s.require_paths = ["lib"]
|
36
|
-
s.rubygems_version = "
|
36
|
+
s.rubygems_version = "2.0.3"
|
37
37
|
s.summary = "a google reader api (unofficial) written in ruby"
|
38
|
-
|
39
|
-
if s.respond_to? :specification_version then
|
40
|
-
s.specification_version = 3
|
41
|
-
|
42
|
-
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
43
|
-
else
|
44
|
-
end
|
45
|
-
else
|
46
|
-
end
|
47
38
|
end
|
48
39
|
|
data/README.mdown
CHANGED
@@ -15,7 +15,10 @@ the api class provided.
|
|
15
15
|
# OR
|
16
16
|
|
17
17
|
api = GoogleReaderApi::Api.new {:auth => 'token'}
|
18
|
-
|
18
|
+
|
19
|
+
# OR If your token was getted from oauth2 (bearer token)
|
20
|
+
|
21
|
+
api = GoogleReaderApi::Api.new {:auth => 'token', :auth_type => :bearer}
|
19
22
|
|
20
23
|
|
21
24
|
and then you can perform requests using the `get_link` and `post_link` methods.
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.5.0
|
@@ -20,6 +20,7 @@ module GoogleReaderApi
|
|
20
20
|
def initialize(options)
|
21
21
|
if options[:auth]
|
22
22
|
@auth = options[:auth]
|
23
|
+
@auth_type = options[:auth_type] || :client_login
|
23
24
|
else
|
24
25
|
request_auth(options[:email],options[:password])
|
25
26
|
end
|
@@ -65,7 +66,11 @@ module GoogleReaderApi
|
|
65
66
|
|
66
67
|
def request(uri,request)
|
67
68
|
# add the cookie to the http header
|
68
|
-
|
69
|
+
if @auth_type == :bearer
|
70
|
+
request.add_field('Authorization',"Bearer #{auth}")
|
71
|
+
else
|
72
|
+
request.add_field('Authorization',"GoogleLogin auth=#{auth}")
|
73
|
+
end
|
69
74
|
res = Net::HTTP.start(uri.host,uri.port) do |http|
|
70
75
|
http.request(request)
|
71
76
|
end
|
metadata
CHANGED
@@ -1,15 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: GoogleReaderApi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.5.0
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Toon Willems
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2013-04-09 00:00:00.000000000 Z
|
13
12
|
dependencies: []
|
14
13
|
description: a google reader api (unofficial) written in ruby
|
15
14
|
email: willemstoon@gmail.com
|
@@ -34,27 +33,25 @@ files:
|
|
34
33
|
- lib/google_reader_api.rb
|
35
34
|
homepage: http://github.com/nudded/GoogleReaderAPI
|
36
35
|
licenses: []
|
36
|
+
metadata: {}
|
37
37
|
post_install_message:
|
38
38
|
rdoc_options: []
|
39
39
|
require_paths:
|
40
40
|
- lib
|
41
41
|
required_ruby_version: !ruby/object:Gem::Requirement
|
42
|
-
none: false
|
43
42
|
requirements:
|
44
|
-
- -
|
43
|
+
- - '>='
|
45
44
|
- !ruby/object:Gem::Version
|
46
45
|
version: '0'
|
47
46
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
48
|
-
none: false
|
49
47
|
requirements:
|
50
|
-
- -
|
48
|
+
- - '>='
|
51
49
|
- !ruby/object:Gem::Version
|
52
50
|
version: '0'
|
53
51
|
requirements: []
|
54
52
|
rubyforge_project:
|
55
|
-
rubygems_version:
|
53
|
+
rubygems_version: 2.0.3
|
56
54
|
signing_key:
|
57
|
-
specification_version:
|
55
|
+
specification_version: 4
|
58
56
|
summary: a google reader api (unofficial) written in ruby
|
59
57
|
test_files: []
|
60
|
-
has_rdoc:
|