yt 0.25.0 → 0.25.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: c48d92d6630a165285e513cfac2088f1db048ecd
4
- data.tar.gz: 06daf58ac858adcc4530aa48020d75f54fc2ece9
3
+ metadata.gz: e9fd88acf793e77574d16b31819944cd77df882d
4
+ data.tar.gz: 7e535a7e4c88f91477f2ccc19ce7ad5d4c1968cc
5
5
  SHA512:
6
- metadata.gz: e884999cfe988df346878d3ddadd92192b13a05f83df035b452baf7ee7ee2f1bc3987ade999138a2a87af71a443beb9ea82ea038a948a95207054b2594d866ff
7
- data.tar.gz: 80a2a1a53bd6faf28b3f629a4b7a051931e9be437428497237c2fdaa235c8bf3c1750094896aefd3c172277ab10e337b3317e19d243049608312eadf0a547ae8
6
+ metadata.gz: 8eed1c36c8d41ae347a6bf9f951842446415efdf8bd9df139973122366fda9f772ffcf5aa7da08c87aa576c382c4364ddadfec8ebefa0717e9355874f5bea548
7
+ data.tar.gz: 0cd8c87df0590b986dd1e72d6f7332dc633505386cfe6514595591efa237828df096ae610cb72ba946edc5024543cb84c45220d0b9bfc26b09a982ac7e437824
data/CHANGELOG.md CHANGED
@@ -6,6 +6,10 @@ For more information about changelogs, check
6
6
  [Keep a Changelog](http://keepachangelog.com) and
7
7
  [Vandamme](http://tech-angels.github.io/vandamme).
8
8
 
9
+ ## 0.25.1 - 2015-07-06
10
+
11
+ * [ENHANCEMENT] `Yt::Video.new` accepts embedded video url.
12
+
9
13
  ## 0.25.0 - 2015-06-29
10
14
 
11
15
  **How to upgrade**
@@ -709,4 +713,4 @@ If you want the old behavior, replace `subscribe` with `subscribe!`:
709
713
 
710
714
  * Support for authenticated resources: Youtube accounts and Google accounts
711
715
  * Support for public Youtube resources: channels and videos
712
- * Available actions for authenticated Youtube accounts: like a video, subscribe to a channel
716
+ * Available actions for authenticated Youtube accounts: like a video, subscribe to a channel
data/README.md CHANGED
@@ -41,7 +41,7 @@ To install on your system, run
41
41
 
42
42
  To use inside a bundled Ruby project, add this line to the Gemfile:
43
43
 
44
- gem 'yt', '~> 0.25.0'
44
+ gem 'yt', '~> 0.25.1'
45
45
 
46
46
  Since the gem follows [Semantic Versioning](http://semver.org),
47
47
  indicating the full version in your Gemfile (~> *major*.*minor*.*patch*)
@@ -259,8 +259,11 @@ In order to use Yt you must register your app in the [Google Developers Console]
259
259
  If you don’t have a registered app, browse to the console and select "Create Project":
260
260
  ![01-create-project](https://cloud.githubusercontent.com/assets/7408595/3373043/4224c894-fbb0-11e3-9f8a-4d96bddce136.png)
261
261
 
262
- When your project is ready, select APIs & Auth in the menu and enable Google+, YouTube Analytics and YouTube Data API:
263
- ![02-select-api](https://cloud.githubusercontent.com/assets/7408595/3373046/4226ea34-fbb0-11e3-9a44-872871e8b297.png)
262
+ When your project is ready, select APIs & Auth in the menu and individually enable Google+, YouTube Analytics and YouTube Data API:
263
+ ![02-select-api](https://cloud.githubusercontent.com/assets/4453997/8442701/5d0f77f4-1f35-11e5-93d8-07d4459186b5.png)
264
+ ![02a-enable google api](https://cloud.githubusercontent.com/assets/4453997/8442306/0f714cb8-1f33-11e5-99b3-f17a4b1230fe.png)
265
+ ![02b-enable youtube api](https://cloud.githubusercontent.com/assets/4453997/8442304/0f6fd0e0-1f33-11e5-981a-acf90ccd7409.png)
266
+ ![02c-enable youtube analytics api](https://cloud.githubusercontent.com/assets/4453997/8442305/0f71240e-1f33-11e5-9b60-4ecea02da9be.png)
264
267
 
265
268
  The next step is to create an API key. Depending on the nature of your app, you should pick one of the following strategies.
266
269
 
data/lib/yt/models/url.rb CHANGED
@@ -71,6 +71,7 @@ module Yt
71
71
  %W{
72
72
  youtube\\.com/watch\\?v=#{video_id}
73
73
  youtu\\.be/#{video_id}
74
+ youtube\\.com/embed/#{video_id}
74
75
  }
75
76
  end
76
77
 
@@ -86,4 +87,4 @@ module Yt
86
87
  end
87
88
  end
88
89
  end
89
- end
90
+ end
data/lib/yt/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Yt
2
- VERSION = '0.25.0'
2
+ VERSION = '0.25.1'
3
3
  end
@@ -19,6 +19,12 @@ describe Yt::URL do
19
19
  it {expect(url.id).to eq 'MESycYJytkU' }
20
20
  end
21
21
 
22
+ context 'given an embed video URL' do
23
+ let(:text) { 'https://www.youtube.com/embed/MESycYJytkU' }
24
+ it {expect(url.kind).to eq :video }
25
+ it {expect(url.id).to eq 'MESycYJytkU' }
26
+ end
27
+
22
28
  context 'given a playlist-embedded video URL' do
23
29
  let(:text) { 'youtube.com/watch?v=MESycYJytkU&list=LLxO1tY8h1AhOz0T4ENwmpow' }
24
30
  it {expect(url.kind).to eq :video }
@@ -69,4 +75,4 @@ describe Yt::URL do
69
75
  let(:text) { 'https://www.youtube.com/user/Fullscreen/' }
70
76
  it {expect(url.kind).to eq :channel }
71
77
  end
72
- end
78
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.25.0
4
+ version: 0.25.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Claudio Baccigalupo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-29 00:00:00.000000000 Z
11
+ date: 2015-07-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport