gotenberg-ruby 1.0.6 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +17 -0
- data/lib/gotenberg/chromium.rb +0 -1
- data/lib/gotenberg/version.rb +1 -1
- data/lib/gotenberg-ruby.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef6aa667b1051bd3bbf25a2b0e269fe9d38126b3bf6b7124d762daac1295e09b
|
4
|
+
data.tar.gz: 68f75974623473b6c328e7a920a09aa85ab72883d48b855d8272c61fd63e5d51
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c0e9c3399c0b0353a0967cecdd1a4a9a302cdc3d28e1ef107c74eb80653c8a8d8c1ca4cf98e43dbe333fc1dd36fc23a2177fa6243b8a044d333ab7399738b04
|
7
|
+
data.tar.gz: 465edabe6fc547b787c84ec23d84bef8e06505e24d963050b0103d96f335b7b986024f60289f283a4024da2a2b4049e905ace013b363cd5736f592a5e07da13f
|
data/README.md
CHANGED
@@ -25,6 +25,7 @@ gem "gotenberg-ruby"
|
|
25
25
|
* [LibreOffice](#libreOffice)
|
26
26
|
* [PDF Engines](#pdf-engines)
|
27
27
|
* [Webhook](#webhook)
|
28
|
+
* [Exiftools](#exiftools)
|
28
29
|
|
29
30
|
### Run Gotenberg
|
30
31
|
|
@@ -640,3 +641,19 @@ document = Gotenberg::Chromium.call(ENV['GOTENBERG_URL']) do |doc|
|
|
640
641
|
doc.webhook 'https://my.webhook.url', 'https://my.webhook.error.url'
|
641
642
|
end
|
642
643
|
```
|
644
|
+
|
645
|
+
### Exiftools
|
646
|
+
|
647
|
+
Gem also proxify (expert mode) access to mini_exiftools througth *Gotenberg::Exiftools* class.
|
648
|
+
You can change PDF metadata manually:
|
649
|
+
|
650
|
+
```ruby
|
651
|
+
binary = Gotenberg::Exiftools.modify(pdf_binary, { title: 'Document 1' })
|
652
|
+
|
653
|
+
# save PDF file
|
654
|
+
File.open('filename.pdf', 'wb') do |file|
|
655
|
+
file << binary
|
656
|
+
end
|
657
|
+
```
|
658
|
+
|
659
|
+
⚠️ Class is just wrapper around *MiniExiftool* class, so you need handle exceptions manually/carefully in begin/rescue block.
|
data/lib/gotenberg/chromium.rb
CHANGED
data/lib/gotenberg/version.rb
CHANGED
data/lib/gotenberg-ruby.rb
CHANGED
@@ -5,6 +5,7 @@ module Gotenberg
|
|
5
5
|
autoload :Chromium, 'gotenberg/chromium'
|
6
6
|
autoload :Libreoffice, 'gotenberg/libreoffice'
|
7
7
|
autoload :PdfEngines, 'gotenberg/pdf_engines'
|
8
|
+
autoload :Exiftools, 'gotenberg/exiftools'
|
8
9
|
autoload :Configuration, 'gotenberg/configuration'
|
9
10
|
|
10
11
|
def self.configuration
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gotenberg-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sanzstez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-10-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|