image_optim_pack 0.5.1.20190105 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (60) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +10 -11
  3. data/CHANGELOG.markdown +5 -0
  4. data/Makefile +2 -1
  5. data/README.markdown +2 -0
  6. data/Vagrantfile +4 -4
  7. data/boxes/Gemfile +0 -3
  8. data/boxes/Rakefile +17 -75
  9. data/boxes/definitions/openbsd-amd64/definition.rb +18 -22
  10. data/boxes/definitions/openbsd-i386/definition.rb +18 -22
  11. data/boxes/definitions/openbsd-postinstall.sh +2 -2
  12. data/image_optim_pack.gemspec +1 -1
  13. data/script/run +29 -12
  14. data/vendor/darwin-i386/advpng +0 -0
  15. data/vendor/darwin-i386/gifsicle +0 -0
  16. data/vendor/darwin-i386/jhead +0 -0
  17. data/vendor/darwin-i386/jpeg-recompress +0 -0
  18. data/vendor/darwin-i386/jpegoptim +0 -0
  19. data/vendor/darwin-i386/jpegtran +0 -0
  20. data/vendor/darwin-i386/libjpeg.dylib +0 -0
  21. data/vendor/darwin-i386/libpng.dylib +0 -0
  22. data/vendor/darwin-i386/libz.dylib +0 -0
  23. data/vendor/darwin-i386/optipng +0 -0
  24. data/vendor/darwin-i386/pngcrush +0 -0
  25. data/vendor/darwin-x86_64/advpng +0 -0
  26. data/vendor/darwin-x86_64/gifsicle +0 -0
  27. data/vendor/darwin-x86_64/jhead +0 -0
  28. data/vendor/darwin-x86_64/jpeg-recompress +0 -0
  29. data/vendor/darwin-x86_64/jpegoptim +0 -0
  30. data/vendor/darwin-x86_64/jpegtran +0 -0
  31. data/vendor/darwin-x86_64/libjpeg.dylib +0 -0
  32. data/vendor/darwin-x86_64/libpng.dylib +0 -0
  33. data/vendor/darwin-x86_64/libz.dylib +0 -0
  34. data/vendor/darwin-x86_64/optipng +0 -0
  35. data/vendor/darwin-x86_64/pngcrush +0 -0
  36. data/vendor/openbsd-amd64/advpng +0 -0
  37. data/vendor/openbsd-amd64/gifsicle +0 -0
  38. data/vendor/openbsd-amd64/jhead +0 -0
  39. data/vendor/openbsd-amd64/jpeg-recompress +0 -0
  40. data/vendor/openbsd-amd64/jpegoptim +0 -0
  41. data/vendor/openbsd-amd64/jpegtran +0 -0
  42. data/vendor/openbsd-amd64/libjpeg.so +0 -0
  43. data/vendor/openbsd-amd64/libpng.so +0 -0
  44. data/vendor/openbsd-amd64/libz.so +0 -0
  45. data/vendor/openbsd-amd64/optipng +0 -0
  46. data/vendor/openbsd-amd64/pngcrush +0 -0
  47. data/vendor/openbsd-amd64/pngquant +0 -0
  48. data/vendor/openbsd-i386/advpng +0 -0
  49. data/vendor/openbsd-i386/gifsicle +0 -0
  50. data/vendor/openbsd-i386/jhead +0 -0
  51. data/vendor/openbsd-i386/jpeg-recompress +0 -0
  52. data/vendor/openbsd-i386/jpegoptim +0 -0
  53. data/vendor/openbsd-i386/jpegtran +0 -0
  54. data/vendor/openbsd-i386/libjpeg.so +0 -0
  55. data/vendor/openbsd-i386/libpng.so +0 -0
  56. data/vendor/openbsd-i386/libz.so +0 -0
  57. data/vendor/openbsd-i386/optipng +0 -0
  58. data/vendor/openbsd-i386/pngcrush +0 -0
  59. data/vendor/openbsd-i386/pngquant +0 -0
  60. metadata +4 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4ab0744335f56090664a6250c276d9b5024a819abfd1d0ace5c6e87486852582
4
- data.tar.gz: c0a6bd6684eb7c5aa43c0ab19e3c74968e229ed00b0b939939f0fa576b35c769
3
+ metadata.gz: 1bf65be0ea0db992bfdb716324ab09be7c8b0c6fd85d1381bd3165316457c888
4
+ data.tar.gz: '09ebaccd0bc3591aa4ee4dfcb153d0467cef9b3400ae99cfa023ec82498d3f02'
5
5
  SHA512:
6
- metadata.gz: a3a1e7a4655ccb1bc64568f2c75d5054ea0c99fdfc698944d9baad1e13a4f4aa1bb8f49d1f76a4f766121e1f6cf6da23795ef5cc0ed9a8d1bd9a35e279221f35
7
- data.tar.gz: f69b8d447627ffff8a63f606688dc07a6625da012dd90f4c422cf01d051997ee67441012176d328138d80b354f6a385f90ed6f32166f3609eb717bf2175f12ea
6
+ metadata.gz: 8b1fb9ed77939ef80812ebb495a85e254838af742f40ccf3614f7c6262cb2214c1369113dfbc8a5ee6181a644437f1b1aa237a900163a95f9e208edb14f05436
7
+ data.tar.gz: eaadc7764e61d67cee2311871326f1dec1b079011e366f567102734218b5d010d888414d254f5dfc10449950093b27565234a49a3c8d049d8b2a4f93ae9a4244
data/.travis.yml CHANGED
@@ -7,19 +7,18 @@ rvm:
7
7
  - '2.1.10'
8
8
  - '2.2.10'
9
9
  - '2.3.8'
10
- - '2.4.5'
11
- - '2.5.3'
12
- - '2.6.0'
13
- - 'jruby-9.0.5.0'
10
+ - '2.4.6'
11
+ - '2.5.5'
12
+ - '2.6.2'
14
13
  - 'jruby-9.1.9.0'
15
14
  script:
16
15
  - make test
17
16
  - bundle exec image_optim --info
18
17
  - bundle exec rspec
19
18
  before_install:
20
- - gem install bundler || gem install bundler --version '< 2'
21
- - ruby -e 'require "rubygems"; require "bundler/inline"; gemfile{ source "https://rubygems.org"; gem "rubygems-update" }' # get compatible version of rubygems-update
19
+ - gem install rubygems-update || gem install rubygems-update --version '< 3'
22
20
  - gem update --system
21
+ - gem install bundler || gem install bundler --version '< 2'
23
22
  - if [ $TRAVIS_OS_NAME == osx ]; then brew update && brew install imagemagick; fi
24
23
  - make ldd-version
25
24
  matrix:
@@ -28,16 +27,16 @@ matrix:
28
27
  rvm: default
29
28
  - os: osx
30
29
  rvm: default
31
- osx_image: xcode7.3
30
+ osx_image: xcode8.3
32
31
  - os: osx
33
32
  rvm: default
34
- osx_image: xcode8.3
33
+ osx_image: xcode9.4
35
34
  - os: osx
36
35
  rvm: default
37
- osx_image: xcode9.3
36
+ osx_image: xcode10.1
38
37
  - env: RUBOCOP=✓
39
- rvm: '2.5.3'
38
+ rvm: '2.6.2'
40
39
  script: bundle exec rubocop
41
40
  - env: CHECK_RUBIES=✓
42
- rvm: '2.5.3'
41
+ rvm: '2.6.2'
43
42
  script: bundle exec travis_check_rubies
data/CHANGELOG.markdown CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  ## unreleased
4
4
 
5
+ ## v0.5.2 (2019-04-10)
6
+
7
+ * Use libc++ instead of libstdc++ on darwin and set deployment target to 10.7 [#15](https://github.com/toy/image_optim_pack/issues/15) [@toy](https://github.com/toy)
8
+ * Switch to openbsd 5.9 [@toy](https://github.com/toy)
9
+
5
10
  ## v0.5.1.20190105 (2019-01-05)
6
11
 
7
12
  * jhead 3.03 [@toy](https://github.com/toy)
data/Makefile CHANGED
@@ -327,8 +327,9 @@ export CPPFLAGS = $(GCC_FLAGS)
327
327
  export LDFLAGS = $(GCC_FLAGS)
328
328
 
329
329
  ifdef IS_DARWIN
330
- export MACOSX_DEPLOYMENT_TARGET := 10.6
330
+ export MACOSX_DEPLOYMENT_TARGET := 10.7
331
331
  GCC_FLAGS += -arch $(ARCH)
332
+ CXXFLAGS += -stdlib=libc++
332
333
  endif
333
334
 
334
335
  ifdef IS_BSD
data/README.markdown CHANGED
@@ -10,6 +10,8 @@ Precompiled binaries for [`image_optim`](https://github.com/toy/image_optim).
10
10
 
11
11
  Contains binaries for Mac OS X (>= 10.6, i386 and x86\_64), Linux (i686 and x86\_64), FreeBSD (i386 and amd64) and OpenBSD (i386 and amd64).
12
12
 
13
+ A test application with latest `image_optim` and `image_optim_pack` is available on heroku: https://iopack.herokuapp.com/.
14
+
13
15
  ## Binaries and libraries
14
16
 
15
17
  * [advpng](http://www.advancemame.it/doc-advpng.html) by Andrea Mazzoleni and Filipe Estima ([GNU GPLv3](acknowledgements/advancecomp.txt))
data/Vagrantfile CHANGED
@@ -48,10 +48,10 @@ Vagrant.configure('2') do |config|
48
48
  <<-SH
49
49
  set -ex
50
50
  pkg_add -z rsync-- ntp gmake gtar-- wget g++-4.8.2p2 autoconf-2.69 automake-1.14.1 libtool nasm
51
- path=/home/vagrant/shared
52
- mkdir -p $path
53
- chown vagrant:vagrant $path
54
- ln -nfs $path /vagrant
51
+ real_workdir_path=/home/vagrant/shared
52
+ mkdir -p $real_workdir_path
53
+ chown vagrant:vagrant $real_workdir_path
54
+ ln -nfs $real_workdir_path /vagrant
55
55
  SH
56
56
  end
57
57
 
data/boxes/Gemfile CHANGED
@@ -3,9 +3,6 @@ source 'https://rubygems.org'
3
3
  gem 'rake'
4
4
 
5
5
  gem 'veewee', '= 0.4.5.1'
6
- gem 'dotenv', '~> 2.0'
7
- gem 'atlas', '~> 1.3'
8
- gem 'progress', '~> 3.1'
9
6
 
10
7
  gem 'net-scp'
11
8
  gem 'progressbar', '~> 0.21.0'
data/boxes/Rakefile CHANGED
@@ -1,38 +1,15 @@
1
- require 'atlas'
2
- require 'dotenv/tasks'
3
1
  require 'pathname'
4
- require 'progress'
5
-
6
- # Show progress when file is read by excon used by atlas
7
- class BodyProgress # :nodoc:
8
- def initialize(path, &block)
9
- fail ArgumentError, 'block required' unless block
10
-
11
- @io = File.open(path)
12
- Progress.start(path, File.size(path)) do
13
- yield self
14
- end
15
- end
16
-
17
- def size
18
- @io.size
19
- end
20
-
21
- def read(length)
22
- data = @io.read(length)
23
- Progress.step data.length if data
24
- data
25
- end
26
- end
27
2
 
28
3
  class Box # :nodoc:
29
- attr_reader :definition_path, :definition_dir, :name, :path
4
+ attr_reader :definition_path, :definition_dir, :name, :path, :groups
30
5
 
31
6
  def initialize(definition_path)
32
7
  @definition_path = Pathname(definition_path)
33
8
  @definition_dir = @definition_path.dirname
34
9
  @name = @definition_dir.basename.to_s
35
10
  @path = Pathname("#{@name}.box")
11
+ parts = @name.split('-')
12
+ @groups = (1...parts.length).map{ |n| parts.take(n).join('-') }
36
13
  end
37
14
 
38
15
  def dependencies
@@ -55,26 +32,6 @@ class Box # :nodoc:
55
32
  sh(*%W[vagrant box add --force --name boxes/#{path} #{path}])
56
33
  end
57
34
 
58
- def upload(version)
59
- assert_box_created
60
-
61
- box = Atlas::Box.create({
62
- :username => 'image_optim_pack',
63
- :name => name,
64
- :short_description => "minimal #{name} (bash, wget) from #{definition[:iso_file]}",
65
- })
66
-
67
- version = box.create_version(:version => version)
68
-
69
- provider = version.create_provider(:name => 'virtualbox')
70
-
71
- BodyProgress.new(path) do |f|
72
- provider.upload(f)
73
- end
74
-
75
- version.release
76
- end
77
-
78
35
  private
79
36
 
80
37
  def definition
@@ -92,49 +49,34 @@ private
92
49
  end
93
50
  end
94
51
 
95
- task :atlas => :dotenv do
96
- token = ENV['ATLAS_TOKEN'].to_s
97
- fail 'ATLAS_TOKEN missing' if token.empty?
98
-
99
- Atlas.configure do |config|
100
- config.access_token = token
101
- end
102
- end
103
-
104
- desc 'build all boxes'
105
- task :build
106
-
107
- desc 'add all boxes to vagrant'
108
- task :add
109
-
110
- desc 'upload all boxes to atlas'
111
- task :upload
112
-
113
- version = Time.now.strftime('%Y%m%d.0.0')
114
52
  Dir['definitions/*/definition.rb'].each do |definition_path|
115
53
  box = Box.new(definition_path)
116
54
 
117
- desc "build #{box.path}"
55
+ desc "build #{box.name} box"
118
56
  file box.path => box.dependencies do
119
57
  box.build
120
58
  end
121
- task :build => box.path
122
59
 
123
60
  namespace :add do
124
- desc "add #{box.path}"
61
+ desc "add #{box.name} box to vagrant"
125
62
  task box.name => box.path do
126
63
  box.add
127
64
  end
128
65
  end
129
- task :add => "add:#{box.name}"
130
66
 
131
- namespace :upload do
132
- desc "upload #{box.path}"
133
- task box.name => [:atlas, box.path] do
134
- box.upload(version)
135
- end
67
+ box.groups.each do |group|
68
+ desc "build #{group} boxes"
69
+ task "build:#{group}" => box.path
70
+
71
+ desc "add #{group} boxes to vagrant"
72
+ task "add:#{group}" => "add:#{box.name}"
136
73
  end
137
- task :upload => "upload:#{box.name}"
74
+
75
+ desc 'build all boxes'
76
+ task :build => box.path
77
+
78
+ desc 'add all boxes to vagrant'
79
+ task :add => "add:#{box.name}"
138
80
  end
139
81
 
140
82
  desc 'remove *.box and iso dir'
@@ -5,50 +5,46 @@ Veewee::Session.declare({
5
5
  :disk_format => 'VDI',
6
6
  :hostiocache => 'off',
7
7
  :os_type_id => 'OpenBSD_64',
8
- :iso_file => 'OpenBSD-5.5-amd64.iso',
9
- :iso_src => 'https://www.mirrorservice.org/pub/OpenBSD/5.5/amd64/install55.iso',
10
- :iso_sha256 => 'cc465ce3f8397883e91c6e1a8a98b1b3507a338984bbfe8978050c5f8fdcaf3f',
8
+ :iso_file => 'OpenBSD-5.9-amd64.iso',
9
+ :iso_src => 'https://www.mirrorservice.org/pub/OpenBSD/5.9/amd64/install59.iso',
10
+ :iso_sha256 => '685262fc665425c61a2952b2820389a2d331ac5558217080e6d564d2ce88eecb',
11
11
  :iso_download_timeout => '1000',
12
12
  :boot_wait => '50',
13
13
  :boot_cmd_sequence => [
14
14
  'I<Enter>', # I - install
15
15
  'us<Enter>', # set the keyboard
16
- 'OpenBSD55-x64<Enter>', # set the hostname
16
+ 'OpenBSD59-x64<Enter>', # set the hostname
17
17
  '<Enter>', # Which nic to config ? [em0]
18
18
  '<Enter>', # do you want dhcp ? [dhcp]
19
19
  '<Wait>' * 5,
20
- 'none<Enter>', # IPV6 for em0 ? [none]
21
- 'done<Enter>', # Which other nic do you wish to configure [done]
20
+ '<Enter>', # IPV6 for em0 ? [none]
21
+ '<Enter>', # Which other nic do you wish to configure [done]
22
22
  'vagrant<Enter>', # Pw for root account
23
23
  'vagrant<Enter>',
24
24
  'yes<Enter>', # Start sshd by default ? [yes]
25
- 'no<Enter>', # Start ntpd by default ? [yes]
26
25
  'no<Enter>', # Do you want the X window system [yes]
27
26
  'vagrant<Enter>', # Setup a user ?
28
27
  'vagrant<Enter>', # Full username
29
28
  'vagrant<Enter>', # Pw for this user
30
29
  'vagrant<Enter>',
31
- 'no<Enter>', # Do you want to disable sshd for root ? [yes]
30
+ 'yes<Enter>', # Do you want to allow sshd for root ? [no]
32
31
  'GB<Enter>', # What timezone are you in ?
33
32
  '<Enter>', # Available disks [sd0]
34
- '<Enter>', # Use DUIDs rather than device names in fstab ? [yes]
35
33
  'W<Enter>', # Use (W)whole disk or (E)edit MBR ? [whole]
36
34
  'A<Enter>', # Use (A)auto layout ... ? [a]
37
- '<Wait>' * 70,
38
- 'cd<Enter>', # location of the sets [cd]
39
- '<Enter>', # Available cd-roms : cd0
40
- '<Enter>', # Pathname to sets ? [5.5/amd64]
41
- '-game55.tgz<Enter>', # Remove games and X
42
- '-xbase55.tgz<Enter>',
43
- '-xetc55.tgz<Enter>',
44
- '-xshare55.tgz<Enter>',
45
- '-xfont55.tgz<Enter>',
46
- '-xserv55.tgz<Enter>',
35
+ '<Wait>' * 5,
36
+ '<Enter>', # location of the sets [cd0]
37
+ '<Enter>', # Pathname to sets ? [5.9/amd64]
38
+ '-game59.tgz<Enter>', # Remove games and X
39
+ '-xbase59.tgz<Enter>',
40
+ '-xshare59.tgz<Enter>',
41
+ '-xfont59.tgz<Enter>',
42
+ '-xserv59.tgz<Enter>',
47
43
  'done<Enter>',
48
44
  '<Wait>',
49
- 'yes<Enter>', # CD does not contain SHA256.sig (5.5) Continue without verification?
50
- 'done<Enter>', # Done installing ?
51
- '<Wait>' * 6,
45
+ 'yes<Enter>', # CD does not contain SHA256.sig (5.9) Continue without verification?
46
+ '<Wait>' * 60,
47
+ 'done<Enter>', # Location of sets?
52
48
  'yes<Enter><Wait>', # Time appears wrong. Set to ...? [yes]
53
49
  '<Wait>' * 6,
54
50
  'reboot<Enter>',
@@ -5,50 +5,46 @@ Veewee::Session.declare({
5
5
  :disk_format => 'VDI',
6
6
  :hostiocache => 'off',
7
7
  :os_type_id => 'OpenBSD',
8
- :iso_file => 'OpenBSD-5.5-i386.iso',
9
- :iso_src => 'https://www.mirrorservice.org/pub/OpenBSD/5.5/i386/install55.iso',
10
- :iso_sha256 => '43798eb4f459b58062167c24337230e96c78b01887a4be40d89279df379f3565',
8
+ :iso_file => 'OpenBSD-5.9-i386.iso',
9
+ :iso_src => 'https://www.mirrorservice.org/pub/OpenBSD/5.9/i386/install59.iso',
10
+ :iso_sha256 => 'd5579f49e1100c3131c674260959ee024b80ad579ea8fff767500652c9691030',
11
11
  :iso_download_timeout => '1000',
12
12
  :boot_wait => '50',
13
13
  :boot_cmd_sequence => [
14
14
  'I<Enter>', # I - install
15
15
  'us<Enter>', # set the keyboard
16
- 'OpenBSD55-x32<Enter>', # set the hostname
16
+ 'OpenBSD59-x32<Enter>', # set the hostname
17
17
  '<Enter>', # Which nic to config ? [em0]
18
18
  '<Enter>', # do you want dhcp ? [dhcp]
19
19
  '<Wait>' * 5,
20
- 'none<Enter>', # IPV6 for em0 ? [none]
21
- 'done<Enter>', # Which other nic do you wish to configure [done]
20
+ '<Enter>', # IPV6 for em0 ? [none]
21
+ '<Enter>', # Which other nic do you wish to configure [done]
22
22
  'vagrant<Enter>', # Pw for root account
23
23
  'vagrant<Enter>',
24
24
  'yes<Enter>', # Start sshd by default ? [yes]
25
- 'no<Enter>', # Start ntpd by default ? [yes]
26
25
  'no<Enter>', # Do you want the X window system [yes]
27
26
  'vagrant<Enter>', # Setup a user ?
28
27
  'vagrant<Enter>', # Full username
29
28
  'vagrant<Enter>', # Pw for this user
30
29
  'vagrant<Enter>',
31
- 'no<Enter>', # Do you want to disable sshd for root ? [yes]
30
+ 'yes<Enter>', # Do you want to allow sshd for root ? [no]
32
31
  'GB<Enter>', # What timezone are you in ?
33
32
  '<Enter>', # Available disks [sd0]
34
- '<Enter>', # Use DUIDs rather than device names in fstab ? [yes]
35
33
  'W<Enter>', # Use (W)whole disk or (E)edit MBR ? [whole]
36
34
  'A<Enter>', # Use (A)auto layout ... ? [a]
37
- '<Wait>' * 70,
38
- 'cd<Enter>', # location of the sets [cd]
39
- '<Enter>', # Available cd-roms : cd0
40
- '<Enter>', # Pathname to sets ? [5.5/i386]
41
- '-game55.tgz<Enter>', # Remove games and X
42
- '-xbase55.tgz<Enter>',
43
- '-xetc55.tgz<Enter>',
44
- '-xshare55.tgz<Enter>',
45
- '-xfont55.tgz<Enter>',
46
- '-xserv55.tgz<Enter>',
35
+ '<Wait>' * 5,
36
+ '<Enter>', # location of the sets [cd0]
37
+ '<Enter>', # Pathname to sets ? [5.9/i386]
38
+ '-game59.tgz<Enter>', # Remove games and X
39
+ '-xbase59.tgz<Enter>',
40
+ '-xshare59.tgz<Enter>',
41
+ '-xfont59.tgz<Enter>',
42
+ '-xserv59.tgz<Enter>',
47
43
  'done<Enter>',
48
44
  '<Wait>',
49
- 'yes<Enter>', # CD does not contain SHA256.sig (5.5) Continue without verification?
50
- 'done<Enter>', # Done installing ?
51
- '<Wait>' * 6,
45
+ 'yes<Enter>', # CD does not contain SHA256.sig (5.9) Continue without verification?
46
+ '<Wait>' * 60,
47
+ 'done<Enter>', # Location of sets?
52
48
  'yes<Enter><Wait>', # Time appears wrong. Set to ...? [yes]
53
49
  '<Wait>' * 6,
54
50
  'reboot<Enter>',
@@ -7,8 +7,8 @@ export PKG_PATH=http://ftp3.usa.openbsd.org/pub/OpenBSD/`uname -r`/packages/`arc
7
7
  echo "export PKG_PATH=$PKG_PATH" >> /root/.profile
8
8
  echo "export PKG_PATH=$PKG_PATH" >> /home/vagrant/.profile
9
9
 
10
- # install bash and wget
11
- pkg_add bash wget
10
+ # install bash, wget and sudo
11
+ pkg_add -z bash wget sudo--
12
12
 
13
13
  # set vagrant shell to bash
14
14
  usermod -s /usr/local/bin/bash vagrant
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'image_optim_pack'
5
- s.version = '0.5.1.20190105'
5
+ s.version = '0.5.2'
6
6
  s.summary = %q{Precompiled binaries for image_optim: advpng, gifsicle, jhead, jpeg-recompress, jpegoptim, jpegtran, optipng, pngcrush, pngquant}
7
7
  s.homepage = "http://github.com/toy/#{s.name}"
8
8
  s.authors = ['Ivan Kuchin']
data/script/run CHANGED
@@ -24,34 +24,51 @@ header() {
24
24
  printf '\033[1;7m######## %s ########\033[0m\n' "$1"
25
25
  }
26
26
 
27
- if [[ `uname -s` != 'Darwin' ]]; then
27
+ if [[ $(uname -s) != 'Darwin' ]]; then
28
28
  echo 'expected to run on Mac OS X'
29
29
  exit 1
30
30
  fi
31
31
 
32
32
  for arch in i386 x86_64; do
33
- passes-filter "darwin-$arch" || continue
34
- header "darwin-$arch"
33
+ platform="darwin-$arch"
34
+ passes-filter "$platform" || continue
35
+ header "$platform"
35
36
 
36
- make $MAKE_TASK ARCH=$arch
37
+ build_dir=~_image_optim/pack
38
+
39
+ mkdir -p "vendor/$platform"
40
+
41
+ sudo -u _image_optim bash -c "
42
+ set -e
43
+
44
+ mkdir -p '$build_dir'
45
+ cd '$build_dir'
46
+
47
+ ln -nsf '$PWD/Makefile' '$PWD/checksums.mk' '$PWD/download' .
48
+ rsync -aR --del '$PWD/./vendor/$platform' .
49
+
50
+ make $MAKE_TASK ARCH=$arch
51
+ "
52
+
53
+ rsync -aR --del "$build_dir/./vendor/$platform" .
37
54
  done
38
55
 
39
56
  for vm in $(perl -pe "s/.*?'(.+?-.+?)'\s+=>\s+'.+?\/.+?'.*|.*/\$1/" Vagrantfile); do
40
57
  passes-filter "$vm" || continue
41
58
  header "$vm"
42
59
 
43
- [[ -n "$NO_UP" ]] || vagrant up $vm
60
+ [[ -n "$NO_UP" ]] || vagrant up "$vm"
44
61
 
45
62
  # create ssh config
46
- ssh_config=.vagrant/ssh_config.$vm
47
- vagrant ssh-config $vm > $ssh_config
63
+ ssh_config=".vagrant/ssh_config.$vm"
64
+ vagrant ssh-config "$vm" > "$ssh_config"
48
65
 
49
66
  # rsync needed files to the box
50
- mkdir -p vendor/$vm
51
- rsync -e "ssh -F $ssh_config" -aR --del Makefile checksums.mk download vendor/$vm $vm:/vagrant
67
+ mkdir -p "vendor/$vm"
68
+ rsync -e "ssh -F $ssh_config" -aR --del Makefile checksums.mk download "vendor/$vm" "$vm:/vagrant"
52
69
 
53
70
  # sync time and run make
54
- ssh -F $ssh_config $vm "
71
+ ssh -F "$ssh_config" "$vm" "
55
72
  set -e
56
73
 
57
74
  sudo ntpdate pool.ntp.org
@@ -65,7 +82,7 @@ for vm in $(perl -pe "s/.*?'(.+?-.+?)'\s+=>\s+'.+?\/.+?'.*|.*/\$1/" Vagrantfile)
65
82
  "
66
83
 
67
84
  # rsync files in vendor from the box
68
- rsync -e "ssh -F $ssh_config" -aR --del $vm:/vagrant/./vendor/$vm .
85
+ rsync -e "ssh -F $ssh_config" -aR --del "$vm:/vagrant/./vendor/$vm" .
69
86
 
70
- [[ -n "$NO_HALT" ]] || vagrant halt $vm
87
+ [[ -n "$NO_HALT" ]] || vagrant halt "$vm"
71
88
  done
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: image_optim_pack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1.20190105
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ivan Kuchin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-05 00:00:00.000000000 Z
11
+ date: 2019-04-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: image_optim
@@ -247,7 +247,7 @@ licenses:
247
247
  metadata:
248
248
  bug_tracker_uri: https://github.com/toy/image_optim_pack/issues
249
249
  changelog_uri: https://github.com/toy/image_optim_pack/blob/master/CHANGELOG.markdown
250
- documentation_uri: https://www.rubydoc.info/gems/image_optim_pack/0.5.1.20190105
250
+ documentation_uri: https://www.rubydoc.info/gems/image_optim_pack/0.5.2
251
251
  source_code_uri: https://github.com/toy/image_optim_pack
252
252
  post_install_message:
253
253
  rdoc_options: []
@@ -264,7 +264,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
264
264
  - !ruby/object:Gem::Version
265
265
  version: '0'
266
266
  requirements: []
267
- rubygems_version: 3.0.2
267
+ rubygems_version: 3.0.3
268
268
  signing_key:
269
269
  specification_version: 4
270
270
  summary: 'Precompiled binaries for image_optim: advpng, gifsicle, jhead, jpeg-recompress,