texsc 0.3.1 → 0.3.2

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: 7a9ce196f041bb2f75dfbc277670ce33f4d9583e64603fbc3721b4506bd80667
4
- data.tar.gz: 324d0dcff1ddd4ca59466d597940be991bb252fa781b36ba7fa46d5f10791011
3
+ metadata.gz: 1338246224d9ddf219b8b4193767dcb6ddc43314ce84e8e1c6379a08176010f2
4
+ data.tar.gz: 740893c232d33535750f17734ae05e160628a40c4994765db96fad1e1186f468
5
5
  SHA512:
6
- metadata.gz: 8f0d81dd04f8cf8290747163a133f294ea7d4cb8a10aa04211a8efe56c3bb06ba3a8ec32827043cf91d7e2e6a5e91047d792cd12eaa43010bc4de3eeb36f085c
7
- data.tar.gz: c52b375086fcd1e6e3b5167295fe49849095ddd79b8ea564318bb823fa845f4566ecf10d6053cfe2e49c4b36bd4f67ebe416b50ee05431d9b799724ccb06e057
6
+ metadata.gz: 308b393c03295b853346781afd52bd68052619240715a00aeb12baca4347bbd646ba1d48c58f774faf0a55f59058149544e604e85b3e29459a8304381e4b5e1e
7
+ data.tar.gz: d2b2056be3591b0b6c68e7eaa9e96765d8c31ee55dd4ca01591a02168a800d6a59d389d7be6dfa1b7381b73bc9cb423baaddbad9aada087e11dce545f32361c9
data/bin/texsc CHANGED
@@ -21,7 +21,7 @@
21
21
  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
22
  # SOFTWARE.
23
23
 
24
- VERSION = '0.3.1'
24
+ VERSION = '0.3.2'
25
25
 
26
26
  STDOUT.sync = true
27
27
 
@@ -70,7 +70,7 @@ Options are:"
70
70
  { cmd: c, opts: o || 'p' }
71
71
  end
72
72
  ignores.each do |i|
73
- tex = tex.gsub(/\\begin{#{i[:cmd]}}.+\\end{#{i[:cmd]}}/m, '')
73
+ tex = tex.gsub(/\\begin{#{Regexp.escape(i[:cmd])}}.+\\end{#{Regexp.escape(i[:cmd])}}/m, '')
74
74
  end
75
75
  log.info("Checking #{f} (#{tex.length} chars)...")
76
76
  cmd = [
@@ -96,6 +96,17 @@ Feature: Command Line Processing
96
96
  When I run bin/texsc with "--ignore nospell:p article.tex"
97
97
  Then Exit code is zero
98
98
 
99
+ Scenario: Bad LaTeX with complex --ignore can be spell checked
100
+ Given I have a "article.tex" file with content:
101
+ """
102
+ \documentclass{article}
103
+ \begin{document}
104
+ How are you, \begin{Nospell*}{test}friiend\end{Nospell*}?
105
+ \end{document}
106
+ """
107
+ When I run bin/texsc with "--ignore Nospell*:p article.tex"
108
+ Then Exit code is zero
109
+
99
110
  Scenario: Bad LaTeX with too short words can be spell checked
100
111
  Given I have a "article.tex" file with content:
101
112
  """
@@ -32,7 +32,7 @@ Gem::Specification.new do |s|
32
32
  s.rubygems_version = '2.2'
33
33
  s.required_ruby_version = '>= 2.3'
34
34
  s.name = 'texsc'
35
- s.version = '0.3.1'
35
+ s.version = '0.3.2'
36
36
  s.license = 'MIT'
37
37
  s.summary = 'Spell Checker for LaTeX'
38
38
  s.description = 'Simple command-line spell checker for LaTeX documents'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: texsc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko