image_optim_pack 0.12.0-arm64-darwin

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.
Files changed (74) hide show
  1. checksums.yaml +7 -0
  2. data/.dockerignore +10 -0
  3. data/.github/dependabot.yml +6 -0
  4. data/.github/workflows/build.yml +47 -0
  5. data/.github/workflows/check.yml +33 -0
  6. data/.github/workflows/docker-build.yml +29 -0
  7. data/.github/workflows/livecheck.yml +35 -0
  8. data/.github/workflows/rubocop.yml +16 -0
  9. data/.gitignore +7 -0
  10. data/.rubocop.yml +97 -0
  11. data/CHANGELOG.markdown +546 -0
  12. data/Dockerfile +184 -0
  13. data/Dockerfile.debian +184 -0
  14. data/Gemfile +10 -0
  15. data/LICENSE.txt +27 -0
  16. data/Makefile +543 -0
  17. data/README.markdown +121 -0
  18. data/acknowledgements/7z.txt +56 -0
  19. data/acknowledgements/advancecomp.txt +674 -0
  20. data/acknowledgements/bmp2png.txt +8 -0
  21. data/acknowledgements/cexcept.txt +8 -0
  22. data/acknowledgements/gifread.txt +14 -0
  23. data/acknowledgements/gifsicle.txt +343 -0
  24. data/acknowledgements/iqa.txt +30 -0
  25. data/acknowledgements/jhead.txt +12 -0
  26. data/acknowledgements/jpeg-archive.txt +20 -0
  27. data/acknowledgements/jpegoptim.txt +339 -0
  28. data/acknowledgements/libjpeg-turbo.txt +27 -0
  29. data/acknowledgements/libjpeg-x86-simd.txt +17 -0
  30. data/acknowledgements/libjpeg.txt +64 -0
  31. data/acknowledgements/liblcms2.txt +21 -0
  32. data/acknowledgements/libpng.txt +90 -0
  33. data/acknowledgements/mozjpeg.txt +7 -0
  34. data/acknowledgements/optipng-authors.txt +26 -0
  35. data/acknowledgements/optipng.txt +21 -0
  36. data/acknowledgements/oxipng.txt +20 -0
  37. data/acknowledgements/pngcrush.txt +35 -0
  38. data/acknowledgements/pngout.txt +9 -0
  39. data/acknowledgements/pngquant.txt +56 -0
  40. data/acknowledgements/smallfry.txt +13 -0
  41. data/acknowledgements/zlib.txt +34 -0
  42. data/acknowledgements/zopfli-contributors.txt +6 -0
  43. data/acknowledgements/zopfli.txt +201 -0
  44. data/checksums.mk +17 -0
  45. data/image_optim_pack-darwin-arm64.gemspec +3 -0
  46. data/image_optim_pack-darwin-x86_64.gemspec +3 -0
  47. data/image_optim_pack-linux-x86_64.gemspec +3 -0
  48. data/image_optim_pack.gemspec +62 -0
  49. data/lib/image_optim/pack.rb +119 -0
  50. data/lib/image_optim_pack.rb +3 -0
  51. data/patches/pngcrush.patch +15 -0
  52. data/script/extract +19 -0
  53. data/script/livecheck +263 -0
  54. data/script/platform_downloads +59 -0
  55. data/script/run +131 -0
  56. data/spec/image_optim/pack_spec.rb +116 -0
  57. data/spec/image_optim_spec.rb +42 -0
  58. data/spec/spec_helper.rb +10 -0
  59. data/vendor/darwin-arm64/advpng +0 -0
  60. data/vendor/darwin-arm64/gifsicle +0 -0
  61. data/vendor/darwin-arm64/jhead +0 -0
  62. data/vendor/darwin-arm64/jpeg-recompress +0 -0
  63. data/vendor/darwin-arm64/jpegoptim +0 -0
  64. data/vendor/darwin-arm64/jpegtran +0 -0
  65. data/vendor/darwin-arm64/libjpeg.dylib +0 -0
  66. data/vendor/darwin-arm64/liblcms2.dylib +0 -0
  67. data/vendor/darwin-arm64/libpng.dylib +0 -0
  68. data/vendor/darwin-arm64/libz.dylib +0 -0
  69. data/vendor/darwin-arm64/optipng +0 -0
  70. data/vendor/darwin-arm64/oxipng +0 -0
  71. data/vendor/darwin-arm64/pngcrush +0 -0
  72. data/vendor/darwin-arm64/pngout +0 -0
  73. data/vendor/darwin-arm64/pngquant +0 -0
  74. metadata +199 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 7054a619a9d9c2ab3fe8e6b5d56cf75176ff2c0042549e11f9475cfe18f185f7
4
+ data.tar.gz: ee11a0371a262672f7f24e83464c61d2eb1c853824bf0da38f62f017c5a5a771
5
+ SHA512:
6
+ metadata.gz: a7ff3d630d743f3e72a412430708d928f246110ce2f4e0ed5cf9efddc7ff552daafb7b4f840e0b73c43b442509fd38bd6f0b8199a66969305e954100c2dacbf4
7
+ data.tar.gz: 1e83cb5474c72f85292bd742e0e1e5a7be940188b8994a8c745e95d767d5ce19a509192b01a5f0b5a893d9d052c901492a57171f115d4b2317d79338c0e0048f
data/.dockerignore ADDED
@@ -0,0 +1,10 @@
1
+ /boxes/
2
+ /.git/
3
+
4
+ /build/
5
+ /.vagrant/
6
+
7
+ Gemfile.lock
8
+ /*.gem
9
+ /.bundle
10
+ /tmp/
@@ -0,0 +1,6 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: github-actions
4
+ directory: /
5
+ schedule:
6
+ interval: weekly
@@ -0,0 +1,47 @@
1
+ name: build
2
+ on:
3
+ push:
4
+ pull_request:
5
+ jobs:
6
+ build-on-linux:
7
+ runs-on: ubuntu-latest
8
+ steps:
9
+ - uses: actions/checkout@v4
10
+ - run: uname -m
11
+ - run: sudo apt-get install -y chrpath
12
+ - run: rustup target list --installed
13
+ - run: make download download-dependencies
14
+ - run: rm -r vendor
15
+ - run: make all
16
+ - uses: actions/upload-artifact@v4
17
+ with:
18
+ name: on-linux
19
+ path: vendor/
20
+ build-on-darwin-x86_64:
21
+ runs-on: macos-13
22
+ steps:
23
+ - uses: actions/checkout@v4
24
+ - run: uname -m
25
+ - run: rustup target add aarch64-apple-darwin
26
+ - run: make download download-dependencies
27
+ - run: rm -r vendor
28
+ - run: make all ARCH=x86_64
29
+ - run: make all ARCH=arm64
30
+ - uses: actions/upload-artifact@v4
31
+ with:
32
+ name: on-darwin-x86_64
33
+ path: vendor/
34
+ build-on-darwin-arm64:
35
+ runs-on: macos-14
36
+ steps:
37
+ - uses: actions/checkout@v4
38
+ - run: uname -m
39
+ - run: rustup target add x86_64-apple-darwin
40
+ - run: make download download-dependencies
41
+ - run: rm -r vendor
42
+ - run: make all ARCH=arm64
43
+ - run: make all test ARCH=x86_64
44
+ - uses: actions/upload-artifact@v4
45
+ with:
46
+ name: on-darwin-arm64
47
+ path: vendor/
@@ -0,0 +1,33 @@
1
+ name: check
2
+ on:
3
+ push:
4
+ pull_request:
5
+ schedule:
6
+ - cron: 45 4 * * 0
7
+ jobs:
8
+ check:
9
+ runs-on: "${{ matrix.os }}"
10
+ strategy:
11
+ matrix:
12
+ os:
13
+ - ubuntu-latest
14
+ - macos-13
15
+ - macos-14
16
+ ruby:
17
+ - '2.7'
18
+ - '3.0'
19
+ - '3.1'
20
+ - '3.2'
21
+ - '3.3'
22
+ - '3.4'
23
+ - jruby-9.4
24
+ fail-fast: false
25
+ steps:
26
+ - uses: actions/checkout@v4
27
+ - uses: ruby/setup-ruby@v1
28
+ with:
29
+ ruby-version: "${{ matrix.ruby }}"
30
+ bundler-cache: true
31
+ - run: make test
32
+ - run: bundle exec image_optim --info
33
+ - run: bundle exec rspec
@@ -0,0 +1,29 @@
1
+ name: docker-build
2
+ on:
3
+ push:
4
+ pull_request:
5
+ workflow_dispatch:
6
+ jobs:
7
+ docker-build:
8
+ runs-on: ubuntu-latest
9
+ strategy:
10
+ matrix:
11
+ params:
12
+ - ''
13
+ - DOCKER_FILE=Dockerfile.debian DOCKER_TAG_SUFFIX=-debian
14
+ fail-fast: false
15
+ steps:
16
+ - uses: actions/checkout@v4
17
+ - uses: docker/login-action@v3
18
+ with:
19
+ registry: ghcr.io
20
+ username: ${{ github.actor }}
21
+ password: ${{ secrets.GITHUB_TOKEN }}
22
+ if: startsWith(github.ref, 'refs/tags/')
23
+ - run: |
24
+ if [[ "$GITHUB_REF" == refs/tags/* ]]; then
25
+ echo "MAKE_ACTION=docker-push" >> $GITHUB_ENV
26
+ else
27
+ echo "MAKE_ACTION=docker-test" >> $GITHUB_ENV
28
+ fi
29
+ - run: make "$MAKE_ACTION" ${{ matrix.params }}
@@ -0,0 +1,35 @@
1
+ name: livecheck
2
+ on:
3
+ push:
4
+ pull_request:
5
+ schedule:
6
+ - cron: 34 5 * * *
7
+ workflow_dispatch:
8
+ inputs:
9
+ retry:
10
+ description: 'Retry attempt'
11
+ required: true
12
+ type: number
13
+ jobs:
14
+ livecheck:
15
+ runs-on: ubuntu-latest
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+ - uses: ruby/setup-ruby@v1
19
+ with:
20
+ ruby-version: '3'
21
+ bundler-cache: true
22
+ - env:
23
+ RETRY: ${{ inputs.retry }}
24
+ RETRIES: 10
25
+ GITHUB_TOKEN: ${{ secrets.RETRY_TOKEN }}
26
+ run: |
27
+ bundle exec script/livecheck || {
28
+ exit_code=$?
29
+ if (( $exit_code == 2 )) && (( ${RETRY:-0} < $RETRIES )); then
30
+ sleep 300
31
+ gh workflow run livecheck --repo $GITHUB_REPOSITORY --ref $GITHUB_REF_NAME -f retry=$(( $RETRY + 1 ))
32
+ else
33
+ exit $exit_code
34
+ fi
35
+ }
@@ -0,0 +1,16 @@
1
+ name: rubocop
2
+ on:
3
+ push:
4
+ pull_request:
5
+ schedule:
6
+ - cron: 45 4 * * 0
7
+ jobs:
8
+ rubocop:
9
+ runs-on: ubuntu-latest
10
+ steps:
11
+ - uses: actions/checkout@v4
12
+ - uses: ruby/setup-ruby@v1
13
+ with:
14
+ ruby-version: '3'
15
+ bundler-cache: true
16
+ - run: bundle exec rubocop
data/.gitignore ADDED
@@ -0,0 +1,7 @@
1
+ /build/
2
+ /download/
3
+
4
+ Gemfile.lock
5
+ /*.gem
6
+ /.bundle
7
+ /tmp/
data/.rubocop.yml ADDED
@@ -0,0 +1,97 @@
1
+ AllCops:
2
+ Exclude:
3
+ - '*.gemspec'
4
+ - 'build/**/*'
5
+ - 'download/**/*'
6
+ - 'vendor/bundle/**/*'
7
+ - Vagrantfile
8
+ NewCops: enable
9
+
10
+ Bundler/OrderedGems:
11
+ Enabled: false
12
+
13
+ Layout/AccessModifierIndentation:
14
+ EnforcedStyle: outdent
15
+
16
+ Layout/DotPosition:
17
+ EnforcedStyle: trailing
18
+
19
+ Layout/FirstHashElementIndentation:
20
+ EnforcedStyle: consistent
21
+
22
+ Layout/LineLength:
23
+ Max: 120
24
+
25
+ Layout/RescueEnsureAlignment:
26
+ Enabled: false
27
+
28
+ Layout/SpaceBeforeBlockBraces:
29
+ EnforcedStyle: no_space
30
+
31
+ Layout/SpaceInsideHashLiteralBraces:
32
+ EnforcedStyle: no_space
33
+
34
+ Metrics/BlockLength:
35
+ Exclude:
36
+ - spec/**/*_spec.rb
37
+
38
+ Metrics/MethodLength:
39
+ Max: 15
40
+
41
+ Security/YAMLLoad:
42
+ Exclude:
43
+ - script/livecheck
44
+
45
+ Style/AccessorGrouping:
46
+ Enabled: false
47
+
48
+ Style/Alias:
49
+ EnforcedStyle: prefer_alias_method
50
+
51
+ Style/DoubleNegation:
52
+ Enabled: false
53
+
54
+ Style/EmptyCaseCondition:
55
+ Enabled: false
56
+
57
+ Style/FormatStringToken:
58
+ Enabled: false
59
+
60
+ Style/HashConversion:
61
+ Enabled: false
62
+
63
+ Style/HashEachMethods:
64
+ Enabled: true
65
+
66
+ Style/HashTransformKeys:
67
+ Enabled: false
68
+
69
+ Style/HashTransformValues:
70
+ Enabled: false
71
+
72
+ Style/IfUnlessModifier:
73
+ Enabled: false
74
+
75
+ Style/MultilineBlockChain:
76
+ Enabled: false
77
+
78
+ Style/RedundantArgument:
79
+ Enabled: false
80
+
81
+ Style/Semicolon:
82
+ AllowAsExpressionSeparator: true
83
+
84
+ Style/SignalException:
85
+ EnforcedStyle: semantic
86
+
87
+ Style/SymbolArray:
88
+ Enabled: false
89
+
90
+ Style/TrailingCommaInArguments:
91
+ EnforcedStyleForMultiline: no_comma
92
+
93
+ Style/TrailingCommaInArrayLiteral:
94
+ EnforcedStyleForMultiline: comma
95
+
96
+ Style/TrailingCommaInHashLiteral:
97
+ EnforcedStyleForMultiline: comma