pretty_strings 0.6.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pretty_strings.rb +1 -0
- data/lib/pretty_strings/version.rb +1 -1
- data/spec/pretty_strings_spec.rb +5 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ae3f5689ac67400cd329561192a4f8bbe23bc3c
|
4
|
+
data.tar.gz: 7598c475d85f9776087bdcaba65cbd2d2a71d785
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1f44192513827565d428a91f0b5c574c8756f55150c26d17b4dfd16d092c6299202886709951a80d792550f86e969d41fe42c3421d0d9eaeede93eff4c9315eb
|
7
|
+
data.tar.gz: a6b9d7e9cd71940ea5747737cfaf82714c8b94d7e7c4d74ceedb425a3d0a66eb0e1450b7e6ee6e9c2ac5e6e2b66203260bdfc47e99b878e568b8a3939191cea9
|
data/lib/pretty_strings.rb
CHANGED
@@ -61,6 +61,7 @@ module PrettyStrings
|
|
61
61
|
end
|
62
62
|
|
63
63
|
def remove_twb_tags_post(text)
|
64
|
+
text.gsub!(/({\\b )([^{}}]*)(}\\line)/, '\2') || text
|
64
65
|
text.gsub!(/({\\\S+ )([^{}}]*)(})/, '\2') || text
|
65
66
|
text.gsub!('\sectd\\linex0\\headery708\\footery708\\colsx708\\endnhere\\sectlinegrid360\\sectdefaultcl\\sftnbj ', '') || text
|
66
67
|
end
|
data/spec/pretty_strings_spec.rb
CHANGED
@@ -199,4 +199,9 @@ describe PrettyStrings do
|
|
199
199
|
text = 'The two most important pieces of information for the carbohydrate controlled diet is the {\cs11\b\cf17 serving size} and the grams of {\cs11\b\cf17 total carbohydrate}.'
|
200
200
|
expect(PrettyStrings::Cleaner.new(text).pretty).to eq('The two most important pieces of information for the carbohydrate controlled diet is the serving size and the grams of total carbohydrate.')
|
201
201
|
end
|
202
|
+
|
203
|
+
it "prettifies example #040" do
|
204
|
+
text = '{\b About ABC Solutions}\line ABC Solutions is a leading provider of mission-critical communication solutions and services for enterprise and government customers.'
|
205
|
+
expect(PrettyStrings::Cleaner.new(text).pretty).to eq('About ABC Solutions ABC Solutions is a leading provider of mission-critical communication solutions and services for enterprise and government customers.')
|
206
|
+
end
|
202
207
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pretty_strings
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kevin S. Dias
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|