latex-decode 0.2.2 → 0.3.0

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
  SHA1:
3
- metadata.gz: b72cef2bcae3250f385227cc6280b46453f9a8a9
4
- data.tar.gz: 594fa9c2ccf9ae5b29935813d850459981679d4f
3
+ metadata.gz: f075a3a6e28fdeb92c9dba6486f56c461936a5a9
4
+ data.tar.gz: 27de3bebcc186f328d8bb6122357933a51baef51
5
5
  SHA512:
6
- metadata.gz: fc225084cca699158fb8ecaa31770d01da0c9fdef2fbf85a15e79d314f06a6515fed8a8a0ff7e1c3502bbb950693fb2672d8d7447eeed102c4d3459c3f0561ea
7
- data.tar.gz: 534f83cba6ca70064c95c41a249a2bc389f39a8e5507ff4def143a34bc8fa3b239f109975ddeca10d7b0a085b5dcf593b09695db602514dc03a4e916a0c48e1f
6
+ metadata.gz: 6810f6ecdddf8d2b27e0bc8b9b80ef1277b3ac1270fa0901f1936edb057a0e19471c8a61768623df8e33661106103a1bebb00963425f324f68fde763a3aada53
7
+ data.tar.gz: 93f809598a9dbb63331c52c6e0b76a866a68103cdca6783ec468eced7b23e937907eae56fcd3f54230fc8b17f45d9047671a0fffe273555896b53efa8f62b7fb
@@ -3,10 +3,10 @@ bundler_args: --without debug
3
3
  sudo: false
4
4
  cache: bundler
5
5
  rvm:
6
- - 1.9.3
7
6
  - 2.0.0
8
7
  - 2.1.0
9
8
  - 2.2.0
9
+ - 2.4.0
10
10
  - jruby-19mode
11
11
  - jruby-head
12
12
  - rbx-2
data/Gemfile CHANGED
@@ -15,7 +15,7 @@ group :debug do
15
15
  gem 'rubinius-compiler', :require => false, :platforms => :rbx
16
16
  end
17
17
 
18
- gem 'unicode', '~> 0.4', :platforms => [:mri, :rbx, :mswin, :mingw]
18
+ gem 'unicode', '~> 0.4', :platforms => [:mri, :rbx, :mswin, :mingw] if RUBY_VERSION < '2.4'
19
19
  gem 'ritex', '~> 1.0.1'
20
20
 
21
21
  gem 'rubysl', '~> 2.0', :platforms => :rbx
@@ -12,12 +12,11 @@ Gem::Specification.new do |s|
12
12
  s.homepage = 'http://github.com/inukshuk/latex-decode'
13
13
  s.summary = 'Decodes LaTeX to Unicode.'
14
14
  s.description = 'Decodes strings formatted in LaTeX to equivalent Unicode strings.'
15
- s.license = 'GPL-3'
15
+ s.license = 'GPL-3.0'
16
16
 
17
17
  if RUBY_PLATFORM =~ /java/
18
18
  s.platform = 'java'
19
19
  else
20
- s.add_dependency('unicode', '~> 0.4')
21
20
  s.platform = 'ruby'
22
21
  end
23
22
 
@@ -30,4 +29,4 @@ Gem::Specification.new do |s|
30
29
  s.extra_rdoc_files = %w{README.md LICENSE}
31
30
  end
32
31
 
33
- # vim: syntax=ruby
32
+ # vim: syntax=ruby
@@ -33,27 +33,35 @@ if RUBY_PLATFORM == 'java'
33
33
  end
34
34
 
35
35
  else
36
- begin
37
- require 'unicode'
38
-
39
- # Use the Unicode gem
36
+ if RUBY_VERSION >= '2.4'
40
37
  module LaTeX
41
38
  def self.normalize_C(string)
42
- Unicode::normalize_C(string)
39
+ string.unicode_normalize(:nfc)
43
40
  end
44
41
  end
45
- rescue LoadError
42
+ else
46
43
  begin
47
- require 'active_support/multibyte/chars'
44
+ require 'unicode'
48
45
 
49
- # Use ActiveSupport's normalizer
46
+ # Use the Unicode gem
50
47
  module LaTeX
51
48
  def self.normalize_C(string)
52
- ActiveSupport::Multibyte::Chars.new(string).normalize(:c).to_s
49
+ Unicode::normalize_C(string)
53
50
  end
54
51
  end
55
52
  rescue LoadError
56
- fail "Failed to load unicode normalizer: please gem install unicode (or active_support)"
53
+ begin
54
+ require 'active_support/multibyte/chars'
55
+
56
+ # Use ActiveSupport's normalizer
57
+ module LaTeX
58
+ def self.normalize_C(string)
59
+ ActiveSupport::Multibyte::Chars.new(string).normalize(:c).to_s
60
+ end
61
+ end
62
+ rescue LoadError
63
+ fail "Failed to load unicode normalizer: please gem install unicode (or active_support)"
64
+ end
57
65
  end
58
66
  end
59
67
  end
@@ -1,5 +1,5 @@
1
1
  module LaTeX
2
2
  module Decode
3
- VERSION = '0.2.2'.freeze
3
+ VERSION = '0.3.0'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: latex-decode
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sylvester Keil
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-03 00:00:00.000000000 Z
12
- dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: unicode
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '0.4'
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '0.4'
11
+ date: 2017-11-03 00:00:00.000000000 Z
12
+ dependencies: []
27
13
  description: Decodes strings formatted in LaTeX to equivalent Unicode strings.
28
14
  email:
29
15
  - http://sylvester.keil.or.at
@@ -64,7 +50,7 @@ files:
64
50
  - lib/latex/decode/version.rb
65
51
  homepage: http://github.com/inukshuk/latex-decode
66
52
  licenses:
67
- - GPL-3
53
+ - GPL-3.0
68
54
  metadata: {}
69
55
  post_install_message:
70
56
  rdoc_options:
@@ -89,7 +75,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
89
75
  version: '0'
90
76
  requirements: []
91
77
  rubyforge_project:
92
- rubygems_version: 2.4.5
78
+ rubygems_version: 2.6.12
93
79
  signing_key:
94
80
  specification_version: 4
95
81
  summary: Decodes LaTeX to Unicode.
@@ -105,4 +91,3 @@ test_files:
105
91
  - features/support/env.rb
106
92
  - features/symbols.feature
107
93
  - features/umlauts.feature
108
- has_rdoc: