youtube-dl.rb 0.3.1.2016.07.11 → 0.3.1.2016.07.13

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: bb4531d7acfc5c8505cf4f48b08c28a8cd862e19
4
- data.tar.gz: 7adf4398b602ac840130e532f62031478b625ba4
3
+ metadata.gz: 32377d690d4e0f4b806ca662be684d3d5d7b78d5
4
+ data.tar.gz: a499ef655905bf0587cd79ec187657112de24777
5
5
  SHA512:
6
- metadata.gz: b37458f50b30a3c7693b7dd5f647594ec5e1586ec9641c2b4cbe056d918af22994053bf85cedc3b9be99667a32fb25601c812261245f68c2167ecf6f2e99ce9a
7
- data.tar.gz: 10b65391bb5dc60bbac19f53421d601b08a410ab30908ba86f7573a135d7672003503b58885cd443db4bc1ed8ce3ea49a432073bc28598efe6df696884e2c717
6
+ metadata.gz: 6f504a2210fc3b2563d9e8bc04c8370fd96d322ec78d4766ef7a05d149030bfe925c6c987f9643f99bda2f2125761608fa48a5fb6474065ec9c8c5fe9cd2ad67
7
+ data.tar.gz: fc28482930e43c6ce4607041cfe03a0a40693c0d96804ed785cd504bbbaf30cc0f92095bc963b0a594906c81ebb49c1a2bb1802841a6bc7df2e5b0b1c1bd7eda
data/Rakefile CHANGED
@@ -25,13 +25,40 @@ namespace :binaries do
25
25
  get_binaries(a[:ver])
26
26
  end
27
27
 
28
- desc 'Auto update binaries and increment version number'
29
- task :update => :latest do
30
- File.open('./lib/youtube-dl/version.rb', 'r+') do |f|
31
- version_file = f.read
32
- f.rewind
33
- f.write version_file.gsub(/\d{4}\.\d+\.\d+\.?\d+?/, `./vendor/bin/youtube-dl --version`.strip)
28
+ desc 'Update the version in version.rb to the vendor youtube-dl version'
29
+ task :update_gem_version do
30
+ # Hack to get the version template from DATA
31
+ _, data = File.read(__FILE__).split(/^__END__$/, 2)
32
+
33
+ version = `./vendor/bin/youtube-dl --version`.strip
34
+ version_filename = './lib/youtube-dl/version.rb'
35
+
36
+ # Compliled template file
37
+ version_file = ERB.new(data).result(binding)
38
+
39
+ # Syntax Check. Throws a SyntaxError if it doesn't work.
40
+ RubyVM::InstructionSequence.compile(version_file)
41
+
42
+ File.open(version_filename, 'w') do |f|
43
+ f.write(version_file)
34
44
  end
35
- abort unless system("git commit -a -m 'Updated binaries to #{`./vendor/bin/youtube-dl --version`.strip}'")
45
+
46
+ abort unless system("git commit -a -m 'Updated binaries to #{version}'")
47
+
48
+ puts "\e[92mSuccessfully updated binaries to version #{version}\e[0m"
36
49
  end
50
+
51
+ desc 'Auto update binaries and increment version number'
52
+ task :update => [:latest, :update_gem_version]
53
+ end
54
+
55
+ __END__
56
+ # Version file
57
+ # If you are updating this code, make sure you are updating
58
+ # lib/youtube-dl/version.rb as well as the Rakefile.
59
+
60
+ module YoutubeDL
61
+ # Semantic Version as well as the bundled binary version.
62
+ # "(major).(minor).(teeny).(pre-release).(binary-version)"
63
+ VERSION = '0.3.1.<%= version %>'.freeze
37
64
  end
@@ -1,8 +1,10 @@
1
+
2
+ # Version file
3
+ # If you are updating this code, make sure you are updating
4
+ # lib/youtube-dl/version.rb as well as the Rakefile.
5
+
1
6
  module YoutubeDL
2
7
  # Semantic Version as well as the bundled binary version.
3
8
  # "(major).(minor).(teeny).(pre-release).(binary-version)"
4
- VERSION = '0.3.1.2016.07.11'.freeze
9
+ VERSION = '0.3.1.2016.07.13'.freeze
5
10
  end
6
-
7
-
8
-
Binary file
Binary file
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.3.1.2016.07.11
4
+ version: 0.3.1.2016.07.13
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: 2016-07-13 00:00:00.000000000 Z
12
+ date: 2016-07-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport