youtube-dl.rb 0.0.3 → 0.0.4
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/.travis.yml +5 -5
- data/README.md +4 -1
- data/lib/youtube-dl/runner.rb +1 -1
- data/lib/youtube-dl/version.rb +1 -1
- data/test/test_helper.rb +7 -2
- data/test/youtube-dl/runner_test.rb +8 -0
- data/vendor/bin/youtube-dl +0 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 06e7be65305bac08f73eb43c881dd2527467ba73
|
4
|
+
data.tar.gz: 899718fd19305a6403afdb323962272a104e6a24
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c4a12fde5f32a50e5f0088f62c88250f318f3f79d51bc64bc4c98d78316bae84595415968b7a088d007ffb239032c23adf61e5bb83d80a8adcc458ee3e44583
|
7
|
+
data.tar.gz: 963a46ce16a4b1b161b503b486409bea3091268040e83aac1a44cace3d4b4d2c1e4ba4e74fcc7a3b201990d098f98adc320f5c576374bde5983d4bde1aaf004b
|
data/.travis.yml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
before_install: 'sudo chmod 755 ./vendor/bin/youtube-dl'
|
2
2
|
rvm:
|
3
|
-
- 1.9.3
|
4
|
-
- 2.0.0
|
5
|
-
- 2.
|
6
|
-
- jruby-19mode
|
7
|
-
- rbx-2
|
3
|
+
- 1.9.3 # EOL, but still supporting
|
4
|
+
- 2.0.0 # Oldest stable
|
5
|
+
- 2.2.2 # Current stable
|
6
|
+
# - jruby-19mode # JRuby
|
7
|
+
- rbx-2 # Rubinius
|
data/README.md
CHANGED
@@ -1,7 +1,10 @@
|
|
1
1
|
# youtube-dl.rb
|
2
2
|
|
3
3
|
Ruby wrapper for [youtube-dl](http://rg3.github.io/youtube-dl/).
|
4
|
+
|
4
5
|
[](https://travis-ci.org/layer8x/youtube-dl.rb)
|
6
|
+
[](https://codeclimate.com/github/layer8x/youtube-dl.rb)
|
7
|
+
[](https://codeclimate.com/github/layer8x/youtube-dl.rb/coverage)
|
5
8
|
|
6
9
|
## Install the gem
|
7
10
|
|
@@ -52,4 +55,4 @@ YoutubeDL.download "https://www.youtube.com/watch?v=gvdf5n-zI14", options
|
|
52
55
|
5. Push to the branch (`git push origin my-new-feature`)
|
53
56
|
6. Create a new Pull Request
|
54
57
|
|
55
|
-
Remember: commit now, commit often.
|
58
|
+
Remember: commit now, commit often.
|
data/lib/youtube-dl/runner.rb
CHANGED
@@ -75,7 +75,7 @@ module YoutubeDL
|
|
75
75
|
def usable_executable_path
|
76
76
|
system_path = `which youtube-dl`
|
77
77
|
if $?.exitstatus == 0
|
78
|
-
system_path
|
78
|
+
system_path.strip
|
79
79
|
else
|
80
80
|
vendor_path = File.absolute_path("#{__FILE__}/../../../vendor/bin/youtube-dl")
|
81
81
|
File.chmod(775, vendor_path) unless File.executable?(vendor_path) # Make sure vendor binary is executable
|
data/lib/youtube-dl/version.rb
CHANGED
data/test/test_helper.rb
CHANGED
@@ -1,5 +1,10 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
if RUBY_PLATFORM == "java"
|
2
|
+
require 'simplecov'
|
3
|
+
SimpleCov.start
|
4
|
+
else
|
5
|
+
require "codeclimate-test-reporter"
|
6
|
+
CodeClimate::TestReporter.start
|
7
|
+
end
|
3
8
|
gem 'minitest'
|
4
9
|
require 'minitest/autorun'
|
5
10
|
require 'minitest/spec'
|
@@ -21,6 +21,14 @@ describe YoutubeDL::Runner do
|
|
21
21
|
assert_match 'youtube-dl', @runner.executable_path
|
22
22
|
end
|
23
23
|
|
24
|
+
it 'should not have a newline char in the executable_path' do
|
25
|
+
assert_match /youtube-dl\z/, @runner.executable_path
|
26
|
+
end
|
27
|
+
|
28
|
+
it 'should not have newline char in to_command' do
|
29
|
+
assert_match /youtube-dl\s/, @runner.to_command
|
30
|
+
end
|
31
|
+
|
24
32
|
it 'should parse key-values from options' do
|
25
33
|
@runner.options.some_key = "a value"
|
26
34
|
|
data/vendor/bin/youtube-dl
CHANGED
File without changes
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: youtube-dl.rb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sapslaj
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-07-
|
12
|
+
date: 2015-07-23 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: cocaine
|