html2doc 0.9.2 → 0.9.3

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
  SHA256:
3
- metadata.gz: 55191304dd43ffe3500f371d089e1b94523dbf66827b58e79a1eee3a6bdd193e
4
- data.tar.gz: 65b07767fae84da8f4224a519307ba4b81d4b2e6f4ca37fc44b2350f5b4f231e
3
+ metadata.gz: 34f2ebe1b5fb0faf57bcb2b73c63ca4d4f4916f0f5daa47d5ec50ca69238ca3e
4
+ data.tar.gz: 16479f56aba64e5c2839546720fe6f2d998d24db42009b3849c788d111ca09d2
5
5
  SHA512:
6
- metadata.gz: f07f8b86bff5b028453453060f52adfb15dbf51276028af83fe52accc290dcee86b05c71f674be62e9917405da7d4a5e0171280e20bb3f6a37d3db2f3271c40b
7
- data.tar.gz: 374db0a1338c2dd0ca433ef5197c903a10d58d1305fe26df29669117070c04b0006b23363a614fab9959b9a004fc6487dd15963c0d756354d23ab59549a42dc0
6
+ metadata.gz: '09cb8b389a2d70dced3d4660b344b7cbc64409017404482c105a2f6f25daa528e27627f4c52b69a74a959b535d87f5d14822ad177156a01232af5466f55d8eeb'
7
+ data.tar.gz: 66b314e12b36f509bcdfade0e24bae06ed5333af57f956c22840a2a1c3b8c8172a891ef30d91072a8e8b18a2e2e34c45146473bcc3e235cb7614a47d8c92a1dd
@@ -2,13 +2,14 @@
2
2
  # use ci-master https://github.com/metanorma/metanorma-build-scripts
3
3
  name: macos
4
4
 
5
- on: [push]
5
+ on: [push, pull_request]
6
6
 
7
7
  jobs:
8
8
  test-macos:
9
9
  name: Test on Ruby ${{ matrix.ruby }} macOS
10
10
  runs-on: macos-latest
11
11
  strategy:
12
+ fail-fast: false
12
13
  matrix:
13
14
  ruby: [ '2.6', '2.5', '2.4' ]
14
15
  steps:
@@ -20,7 +21,7 @@ jobs:
20
21
  architecture: 'x64'
21
22
  - name: Update gems
22
23
  run: |
23
- sudo gem install bundler -v "~> 2" --force
24
+ sudo gem install bundler --force
24
25
  bundle install --jobs 4 --retry 3
25
26
  - name: Run specs
26
27
  run: |
@@ -2,13 +2,14 @@
2
2
  # use ci-master https://github.com/metanorma/metanorma-build-scripts
3
3
  name: ubuntu
4
4
 
5
- on: [push]
5
+ on: [push, pull_request]
6
6
 
7
7
  jobs:
8
8
  test-linux:
9
9
  name: Test on Ruby ${{ matrix.ruby }} Ubuntu
10
10
  runs-on: ubuntu-latest
11
11
  strategy:
12
+ fail-fast: false
12
13
  matrix:
13
14
  ruby: [ '2.6', '2.5', '2.4' ]
14
15
  steps:
@@ -20,7 +21,7 @@ jobs:
20
21
  architecture: 'x64'
21
22
  - name: Update gems
22
23
  run: |
23
- gem install bundler -v "~> 2"
24
+ gem install bundler
24
25
  bundle install --jobs 4 --retry 3
25
26
  - name: Run specs
26
27
  run: |
@@ -2,13 +2,14 @@
2
2
  # use ci-master https://github.com/metanorma/metanorma-build-scripts
3
3
  name: windows
4
4
 
5
- on: [push]
5
+ on: [push, pull_request]
6
6
 
7
7
  jobs:
8
8
  test-windows:
9
9
  name: Test on Ruby ${{ matrix.ruby }} Windows
10
10
  runs-on: windows-latest
11
11
  strategy:
12
+ fail-fast: false
12
13
  matrix:
13
14
  ruby: [ '2.6', '2.5', '2.4' ]
14
15
  steps:
@@ -21,7 +22,7 @@ jobs:
21
22
  - name: Update gems
22
23
  shell: pwsh
23
24
  run: |
24
- gem install bundler -v "~> 2"
25
+ gem install bundler
25
26
  bundle config --local path vendor/bundle
26
27
  bundle update
27
28
  bundle install --jobs 4 --retry 3
data/html2doc.gemspec CHANGED
@@ -33,7 +33,6 @@ Gem::Specification.new do |spec|
33
33
  spec.add_dependency "uuidtools"
34
34
  spec.add_dependency "asciimath", "~> 1.0.9"
35
35
 
36
- spec.add_development_dependency "bundler", "~> 2.0.1"
37
36
  spec.add_development_dependency "byebug", "~> 9.1"
38
37
  spec.add_development_dependency "equivalent-xml", "~> 0.6"
39
38
  spec.add_development_dependency "guard", "~> 2.14"
data/lib/html2doc/mime.rb CHANGED
@@ -116,7 +116,7 @@ module Html2Doc
116
116
  !(%r{ src="data:image/[^;]+;base64}.match a[1])
117
117
  m = / src=['"](?<src>[^"']+)['"]/.match a[1]
118
118
  warnsvg(m[:src])
119
- m2 = /\.(?<suffix>\S+)$/.match m[:src]
119
+ m2 = /\.(?<suffix>[a-zA-Z_0-9]+)$/.match m[:src]
120
120
  new_filename = "file:///C:/Doc/#{filename}_files/#{mkuuid}.#{m2[:suffix]}"
121
121
  old_filename = %r{^([A-Z]:)?/}.match(m[:src]) ? m[:src] : File.join(localdir, m[:src])
122
122
  FileUtils.cp old_filename, File.join(dir, "#{mkuuid}.#{m2[:suffix]}")
@@ -1,3 +1,3 @@
1
1
  module Html2Doc
2
- VERSION = "0.9.2".freeze
2
+ VERSION = "0.9.3".freeze
3
3
  end
@@ -348,7 +348,7 @@ RSpec.describe Html2Doc do
348
348
  File.open("spec/header_img1.html", "w:UTF-8") do |f|
349
349
  f.write doc.sub(%r{spec/19160-6.png}, File.expand_path(File.join(File.dirname(__FILE__), "19160-6.png")))
350
350
  end
351
- Html2Doc.process(html_input(""), filename: "test", header_file: "spec/header_img.html")
351
+ Html2Doc.process(html_input(""), filename: "test", header_file: "spec/header_img1.html")
352
352
  doc = guid_clean(File.read("test.doc", encoding: "utf-8"))
353
353
  expect(doc).to match(%r{Content-Type: image/png})
354
354
  expect(doc).to match(%r{file:///C:/Doc/test_files/[^.]+\.png})
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: html2doc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.2
4
+ version: 0.9.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-19 00:00:00.000000000 Z
11
+ date: 2019-12-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlentities
@@ -108,20 +108,6 @@ dependencies:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
110
  version: 1.0.9
111
- - !ruby/object:Gem::Dependency
112
- name: bundler
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: 2.0.1
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: 2.0.1
125
111
  - !ruby/object:Gem::Dependency
126
112
  name: byebug
127
113
  requirement: !ruby/object:Gem::Requirement