wkhtmltopdf-installer 0.12.3.3 → 0.12.6.2

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
- SHA1:
3
- metadata.gz: 7ba4e1c72abb27b386338621ab9750e97a08a869
4
- data.tar.gz: d26843c1c044cfb431d21f79fef837eb830df1ea
2
+ SHA256:
3
+ metadata.gz: 1f8d57ab6c83d496681d19d20bf623e023039927fe83acf9dae16cb14c669ba4
4
+ data.tar.gz: ab1e11643e0b5de253da6a77e6df860f27689541002fbfb5c58c09d7ef8121db
5
5
  SHA512:
6
- metadata.gz: fdce29b8af569b39156afed2dcd5cfdfcbc4c5567368141db378e06a5d59635dfa2345162e6a9b5b07220673d54c8e7c2b0f3338d44617fb7d17cbb0cd0532ce
7
- data.tar.gz: 1b640e06786948a86fe6de47a0fe7196068b639565530e96f5c42d3d0e551d07482712438ffe8a5ccb0ebcbb52ce311ffd24661b0c73076dcf4f38afe9c11470
6
+ metadata.gz: a639b014792956818e2789abf0c385a6fb25033c55dd269716080208038e482602150d0b080eaf7b4490986f9fba2633fc7f1d5ad8af47889ba239ddf4913079
7
+ data.tar.gz: e510dffb40dddc63e8691ead0c7f567c16ab0b31cbc5da09833615d31538bf28aeb0c2e0494be69ac765604b7c73b0fb450ea8b68f237431770dec7f4857e1c3
data/ext/Makefile.linux CHANGED
@@ -1,5 +1,6 @@
1
- DOWNLOADED = wkhtmltox.tar.xz
2
- BINARY = $(TMPDIR)/wkhtmltox/bin/wkhtmltopdf
1
+ DOWNLOADED = $(TMPDIR)/wkhtmltox.deb
2
+ BINARY = $(TMPDIR)/usr/local/bin/wkhtmltopdf
3
3
 
4
4
  unpack: tmp $(DOWNLOADED)
5
- tar -C $(TMPDIR) -xf $(DOWNLOADED)
5
+ cd $(TMPDIR) && ar -x $(DOWNLOADED) && tar -xf data.tar.xz
6
+
data/ext/Makefile.macos CHANGED
@@ -1,12 +1,12 @@
1
- DOWNLOADED = wkhtmltox.pkg
1
+ DOWNLOADED = $(TMPDIR)/wkhtmltox.pkg
2
2
  BINARY = $(TMPDIR)/bin/wkhtmltopdf
3
3
 
4
4
  pkg_content = $(TMPDIR)/content
5
5
  payload = $(pkg_content)/Payload
6
- app_tar_xz = $(TMPDIR)/usr/local/share/wkhtmltox-installer/app.tar.xz
6
+ app_tar_xz = $(TMPDIR)/usr/local/share/wkhtmltox-installer/wkhtmltox.tar.gz
7
7
 
8
8
  unpack: tmp $(DOWNLOADED)
9
- pkgutil --expand $(DOWNLOADED) $(pkg_content)
10
- tar -xf $(payload) -C $(TMPDIR)
11
- tar -xzf $(app_tar_xz) -C $(TMPDIR)
9
+ /usr/sbin/pkgutil --expand $(DOWNLOADED) $(pkg_content)
10
+ /usr/bin/tar -xf $(payload) -C $(TMPDIR)
11
+ /usr/bin/tar -xzf $(app_tar_xz) -C $(TMPDIR)
12
12
 
data/ext/extconf.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'mkmf'
2
4
  require 'tmpdir'
3
5
  require 'ostruct'
@@ -5,19 +7,19 @@ require_relative '../lib/wkhtmltopdf_installer'
5
7
 
6
8
  def probe
7
9
  @probe ||= case RUBY_PLATFORM
8
- when /x86_64-darwin.*/
9
- OpenStruct.new(script: 'macos', platform: 'osx-cocoa-x86-64', ext: 'pkg')
10
- when /x86_64-linux/
11
- OpenStruct.new(script: 'linux', platform: 'linux-generic-amd64', ext: 'tar.xz')
12
- when /i[3456]86-linux/
13
- OpenStruct.new(script: 'linux', platform: 'linux-generic-i386', ext: 'tar.xz')
14
- else
15
- raise NotImplementedError "Unsupported ruby platform #{RUBY_PLATFORM}"
10
+ when /darwin.*/ # both M1 ARM and x86 are supported for macos
11
+ OpenStruct.new(script: 'macos', platform: 'macos_cocoa', ext: 'pkg')
12
+ when /x86_64-linux/
13
+ OpenStruct.new(script: 'linux', platform: 'linux_amd64', ext: 'deb')
14
+ when /i[3456]86-linux/
15
+ OpenStruct.new(script: 'linux', platform: 'linux_i386', ext: 'deb')
16
+ else
17
+ raise NotImplementedError, "Unsupported ruby platform #{RUBY_PLATFORM}"
16
18
  end
17
19
  end
18
20
 
19
21
  def version
20
- WkhtmltopdfInstaller::VERSION
22
+ WkhtmltopdfInstaller::BINARIES_VERSION
21
23
  end
22
24
 
23
25
  def makefile_dir
@@ -25,12 +27,12 @@ def makefile_dir
25
27
  end
26
28
 
27
29
  # Some examples:
28
- # "http://download.gna.org/wkhtmltopdf/0.12/#{version}/wkhtmltox-#{version}_osx-cocoa-x86-64.pkg"
29
- # "http://download.gna.org/wkhtmltopdf/0.12/#{version}/wkhtmltox-#{version}_linux-generic-amd64.deb"
30
- # "http://download.gna.org/wkhtmltopdf/0.12/#{version}/wkhtmltox-#{version}_linux-generic-i386.deb"
30
+ # "https://github.com/vovayartsev/wkhtmltopdf-installer-ruby/releases/download/0.12.6-1/wkhtmltox-0.12.6-1.linux_amd64.deb"
31
+ # "https://github.com/vovayartsev/wkhtmltopdf-installer-ruby/releases/download/0.12.6-1/wkhtmltox-0.12.6-1.linux_i386.deb"
32
+ # "https://github.com/vovayartsev/wkhtmltopdf-installer-ruby/releases/download/0.12.6-1/wkhtmltox-0.12.6-1.macos_cocoa.pkg"
33
+
31
34
  def package_url
32
- major_version = version.gsub(/^(\d+\.\d+).*$/, '\1')
33
- "http://download.gna.org/wkhtmltopdf/#{major_version}/#{version}/wkhtmltox-#{version}_#{probe.platform}.#{probe.ext}"
35
+ "https://github.com/vovayartsev/wkhtmltopdf-installer-ruby/releases/download/#{version}/wkhtmltox-#{version}.#{probe.platform}.#{probe.ext}"
34
36
  end
35
37
 
36
38
  # The main Makefile contains settings only. The actual work is done by os-specific Makefile.xxxxx files
@@ -44,4 +46,3 @@ install: copy clean
44
46
  include Makefile.#{probe.script}
45
47
  include Makefile.common
46
48
  EOF
47
-
@@ -1,5 +1,11 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module WkhtmltopdfInstaller
2
- VERSION = '0.12.3'.freeze
3
- RELEASE_ITERATION = 3
4
+ # VERSION corresponds to wkhtmltopdf's version
5
+ VERSION = '0.12.6'
6
+ RELEASE_ITERATION = 2
4
7
  GEM_VERSION = "#{VERSION}.#{RELEASE_ITERATION}"
8
+
9
+ # This is a version of binaries from https://github.com/vovayartsev/wkhtmltopdf-installer-ruby/releases
10
+ BINARIES_VERSION = "0.12.6-1"
5
11
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wkhtmltopdf-installer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.3.3
4
+ version: 0.12.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vladimir Yartsev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-19 00:00:00.000000000 Z
11
+ date: 2018-09-02 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Downloads wkhtmltopdf binary during 'Building native extension...' phase
14
14
  email: vovayartsev@gmail.com
@@ -44,8 +44,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
44
44
  - !ruby/object:Gem::Version
45
45
  version: '0'
46
46
  requirements: []
47
- rubyforge_project:
48
- rubygems_version: 2.5.1
47
+ rubygems_version: 3.0.3
49
48
  signing_key:
50
49
  specification_version: 4
51
50
  summary: Light-weight cross-platform wkhtmltopdf binary installer