motion-tube 0.0.2 → 0.0.3
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/README.md +15 -1
- data/lib/motion-tube/parser.rb +1 -1
- data/lib/motion-tube.rb +2 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d61199257e623e4c13bf49f2ed1a3a59a435af26
|
4
|
+
data.tar.gz: efa6b69acde194fb09ddc8ca0a10617e1a904eee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d4e6f57b5c8d3ff23b2c77363fac769185b9220df612e54db6eb3f980c4f68d847eee7a4cc0b13b9d8fa1a155c9bbbff69da993a2404f65d492148488f0f1863
|
7
|
+
data.tar.gz: 6c3dc841e56616fe4d181059650ef0bed56ad6430772fd84130253fd00392f73c8f95b30f0121b7fa5158ff3cda9b8404f6037d9f6d82500b3df2df3057d3776
|
data/README.md
CHANGED
@@ -19,7 +19,21 @@ Or install it yourself as:
|
|
19
19
|
|
20
20
|
## Usage
|
21
21
|
|
22
|
-
|
22
|
+
To play a youtube video can be as simple as:
|
23
|
+
|
24
|
+
```
|
25
|
+
(main)> parser = MotionTube::Parser.new
|
26
|
+
"https://www.youtube.com/watch?v=_S1S1gGS3lU"
|
27
|
+
=> #<MotionTube::Parser:0x10ef5e8b0
|
28
|
+
@url="https://www.youtube.com/watch?v=_S1S1gGS3lU"
|
29
|
+
@rest_client=#<AFHTTPRequestOperationManager:0x10ef5fdd0>>
|
30
|
+
(main)> parser.parse do |result|
|
31
|
+
(main)> puts result[:title]
|
32
|
+
(main)> BW::Media.play_modal result[:media]["mp4"].last
|
33
|
+
(main)> end
|
34
|
+
=> #<AFHTTPRequestOperation:0x10ec3faa0>
|
35
|
+
(main)> CoreDataQuery+(CDQ)+In+Action
|
36
|
+
```
|
23
37
|
|
24
38
|
## Contributing
|
25
39
|
|
data/lib/motion-tube/parser.rb
CHANGED
data/lib/motion-tube.rb
CHANGED
@@ -3,6 +3,8 @@
|
|
3
3
|
unless defined?(Motion::Project::Config)
|
4
4
|
raise "This file must be required within a RubyMotion project Rakefile."
|
5
5
|
end
|
6
|
+
require "afmotion"
|
7
|
+
require 'sugarcube-foundation'
|
6
8
|
|
7
9
|
lib_dir_path = File.dirname(File.expand_path(__FILE__))
|
8
10
|
Motion::Project::App.setup do |app|
|