lingua-it-readability 1.2.0 → 1.2.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a882ae84c810b0133e6ef76d2bac16205b411954
4
- data.tar.gz: c9f681c724fbb40f91b068dd30c1fee500f37c6d
3
+ metadata.gz: ca114de122207c4fd403dc3924048730476c4e76
4
+ data.tar.gz: 39a5096edc53d15f7490431e017df9a32136c066
5
5
  SHA512:
6
- metadata.gz: 9df4807ecb56e41cf2c700fc603c4b0263d19ec29d13e6261c948f29cea85262732bdf43572d4d2703879958a375383cc95e7b0d7c627f7c5c361bbab657fe91
7
- data.tar.gz: 48518468c89a5e3d29a67fb5d28fbe8845f6b5633f982b86b27ed437a10bc62acf8d0f0931ca2324d9dac049de0db54e54d2cad6f91b13858c2e4930124cb341
6
+ metadata.gz: 2241a6fb60d3c1abcaa973ba4f47e783130ce68d3ed9786532b4848d3fb16324f8baf441a31843e72ebd12e728bdd8a2108037301eab6972a4ecd0775191564c
7
+ data.tar.gz: ea25e7858230f530e49db91b8442fc543dc722acdde7771b7504f8e0e1aa24594348e1ef0b123cd2ca7cb8e426e35eef92533f37ab6b8607e2c460bcddcdedd1
@@ -1,7 +1,7 @@
1
1
  module Lingua
2
2
  module It
3
3
  module Readability
4
- VERSION = "1.2.0"
4
+ VERSION = "1.2.1"
5
5
  end
6
6
  end
7
7
  end
@@ -13,10 +13,10 @@ module Lingua
13
13
  end
14
14
 
15
15
  # Common abbreviations
16
- TITLES = %w(sig sigg dott preg prof mr jr amn avv co stim dr egr geom ing mons on rag rev soc spett card ill gent cav) unless defined?(TITLES)
17
- MISC = %w(p v femm dim ecc etc corr cc bcc all es fatt g gg id int lett ogg pag pagg cap pp tel ind v n num min sec ms abbr agg art aus) unless defined?(MISC)
18
- MONTHS = %w(gen feb mar apr mag giu lug ago set sett ott nov dic) unless defined?(MONTHS)
19
- DAYS = %w(lun mar mer gio ven sab dom) unless defined?(DAYS)
16
+ TITLES = %w(Sig Sigg Dott Preg Prof Mr Jr Amn Avv Co Stim Dr Egr Geom Ing Mons On Rag Rev Soc Spett Card Ill Gent Cav) unless defined?(TITLES)
17
+ MISC = %w(P V Femm Dim Ecc Etc Corr Cc Bcc All Es Fatt G Gg Id Int Lett Ogg Pag Pagg Cap Pp Tel Ind V N Num Min Sec Ms Abbr Agg Art Aus) unless defined?(MISC)
18
+ MONTHS = %w(Gen Feb Mar Apr Mag Giu Lug Ago Set Sett Ott Nov Dic) unless defined?(MONTHS)
19
+ DAYS = %w(Lun Mar Mer Gio Ven Sab Dom) unless defined?(DAYS)
20
20
 
21
21
  # Standard delimiters
22
22
  STD = %w(. ? !)
@@ -31,7 +31,7 @@ module Lingua
31
31
  txt.gsub!(/\b(#{@abbr_regex})(\.)\B/i, '\10002')
32
32
  txt.gsub!(/["']?[A-Z][^\Q#{@delim_regex}\E]+((?![\Q#{@delim_regex}\E]['"]?\s["']?[A-Z][^\Q#{@delim_regex}\E]).)+[\Q#{@delim_regex}\E'"]+/, '\2\001')
33
33
  txt.gsub!(/\b(#{@abbr_regex})(0002)/i, '\1.')
34
- txt.split(/01/).map { |sentence| sentence.strip }
34
+ txt.split(/01|\n\s*\n/).map { |sentence| sentence.strip }
35
35
  end
36
36
 
37
37
  # Add customized abbreviations to standard set
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lingua-it-readability
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrea Giacomo Baldan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-02-11 00:00:00.000000000 Z
11
+ date: 2016-02-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler