youtube_query 1.0.1 → 1.0.2
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.
- checksums.yaml +4 -4
- data/lib/youtube_query.rb +3 -13
- data/youtube_query.gemspec +3 -1
- metadata +31 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f9af8c321566c59ac611ebc841227364d64d39e6
|
4
|
+
data.tar.gz: 1594e251a989d797c65d3edd06e3895b9d7db41f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6f9d0a8cf75f54cd395eefc9d2723541d541a12e7c7a01d2f1b54eece6ff81e1714785d2fc5a2da074770e6c0646e5ae042f9e3ffd5559c0fe194320319aa0c2
|
7
|
+
data.tar.gz: 0343d7a867fce004ca4013c9a02134fd65f5c9aa71474a45d6f1220ebf879e7c7d27de629513e7cb480779ce59518d63ee781fc8538fb3cb4562d0c1451054e2
|
data/lib/youtube_query.rb
CHANGED
@@ -2,7 +2,7 @@ require 'google/api_client'
|
|
2
2
|
|
3
3
|
class YouTubeQuery
|
4
4
|
|
5
|
-
def
|
5
|
+
def initialize(options={})
|
6
6
|
|
7
7
|
options = {
|
8
8
|
:youtube_api_service_name => "youtube",
|
@@ -25,18 +25,8 @@ class YouTubeQuery
|
|
25
25
|
:parameters => options
|
26
26
|
)
|
27
27
|
|
28
|
-
|
29
|
-
|
30
|
-
# Add each result to the appropriate list, and then display the lists of
|
31
|
-
# matching videos, channels, and playlists.
|
32
|
-
search_response.data.items.each do |search_result|
|
33
|
-
case search_result.id.kind
|
34
|
-
when 'youtube#video'
|
35
|
-
videos.push("#{search_result.snippet.title} (#{search_result.id.videoId})")
|
36
|
-
end
|
37
|
-
end
|
38
|
-
|
39
|
-
return videos
|
28
|
+
return search_response.data.items
|
40
29
|
|
41
30
|
end
|
31
|
+
|
42
32
|
end
|
data/youtube_query.gemspec
CHANGED
@@ -1,9 +1,11 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'youtube_query'
|
3
|
-
s.version = '1.0.
|
3
|
+
s.version = '1.0.2'
|
4
4
|
s.summary = ''
|
5
5
|
s.description = 'Gem for searching youtube videos'
|
6
6
|
s.authors = ["Martyn Bissett"]
|
7
7
|
s.homepage = 'https://github.com/martynbiz/youtube_query'
|
8
8
|
s.files = Dir.glob("lib/**/*") + %w(README.md youtube_query.gemspec)
|
9
|
+
s.add_runtime_dependency 'google-api-client', ['~> 0.7.1']
|
10
|
+
s.add_development_dependency 'google-api-client', ['~> 0.7.1']
|
9
11
|
end
|
metadata
CHANGED
@@ -1,15 +1,43 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: youtube_query
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Martyn Bissett
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
12
|
-
dependencies:
|
11
|
+
date: 2014-05-12 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: google-api-client
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ~>
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 0.7.1
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 0.7.1
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: google-api-client
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ~>
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.7.1
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ~>
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.7.1
|
13
41
|
description: Gem for searching youtube videos
|
14
42
|
email:
|
15
43
|
executables: []
|