texsc 0.2.0 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -0
- data/README.md +14 -2
- data/bin/texsc +6 -2
- data/features/cli.feature +12 -1
- data/texsc.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1f0e7863fdd9141c6d4d448b60e0feabc45b48bfa2652a93a6bce2cc39fd6087
|
4
|
+
data.tar.gz: 80a989ea2b50f79af5860bb396cbd4a0a6d47aaa9a6bcd368296004c8972b29e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc4ee93d540b0fce8255a43bc4c7f1f744de57cd9e38b93f548af9fcc7857d6d8b25bdb3e2012e80a79b3c6c998ec752000a3473aa91919afec550882f0870b9
|
7
|
+
data.tar.gz: 2d430663f77c0726fc498026dfbad83e94424f0d272f506ff0c2082c23dcebe0ab250d1e665df7e731b9cd2018b79fcf6b5cf04dd4bee2ba5442df345603bbb4
|
data/.travis.yml
CHANGED
data/README.md
CHANGED
@@ -14,7 +14,7 @@
|
|
14
14
|
[![Test Coverage](https://img.shields.io/codecov/c/github/yegor256/texsc.svg)](https://codecov.io/github/yegor256/texsc?branch=master)
|
15
15
|
[![Hits-of-Code](https://hitsofcode.com/github/yegor256/texsc)](https://hitsofcode.com/view/github/yegor256/texsc)
|
16
16
|
|
17
|
-
This tool simplies the usage of [aspell](http://aspell.net/)
|
17
|
+
This tool simplies the usage of [GNU aspell](http://aspell.net/)
|
18
18
|
(you must have it installed)
|
19
19
|
for spell-checking of LaTeX files.
|
20
20
|
|
@@ -30,7 +30,19 @@ Then, you just run it like this for your LaTeX files:
|
|
30
30
|
$ texsc article.tex
|
31
31
|
```
|
32
32
|
|
33
|
-
You may ignore certain tags or environments using `--ignore` option
|
33
|
+
You may ignore certain tags or environments using `--ignore` option
|
34
|
+
|
35
|
+
```bash
|
36
|
+
$ texsc --ignore=citet,citep --ignore=newminted article.tex
|
37
|
+
```
|
38
|
+
|
39
|
+
You can specify the method of ignoring,
|
40
|
+
as [aspell suggests](http://aspell.net/man-html/The-Options.html#TeX_002fLaTeX-Filter)
|
41
|
+
(by default it's 'p'):
|
42
|
+
|
43
|
+
```bash
|
44
|
+
$ texsc --ignore=newminted:opp article.tex
|
45
|
+
```
|
34
46
|
|
35
47
|
You may also use your own additional dictionary, via `--pws` option.
|
36
48
|
The file must contain one word per line:
|
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.
|
24
|
+
VERSION = '0.3.0'
|
25
25
|
|
26
26
|
STDOUT.sync = true
|
27
27
|
|
@@ -76,7 +76,11 @@ Options are:"
|
|
76
76
|
'--lang=en',
|
77
77
|
'--mode=tex',
|
78
78
|
opts[:pws] ? "-p #{opts[:pws]}" : '',
|
79
|
-
opts[:ignore].map
|
79
|
+
opts[:ignore].map do |e|
|
80
|
+
cmd, opts = e.split(':')
|
81
|
+
opts = 'p' if opts.nil?
|
82
|
+
"--add-tex-command '#{cmd} #{opts}'"
|
83
|
+
end.join(' '),
|
80
84
|
'pipe'
|
81
85
|
].join(' ')
|
82
86
|
log.debug(cmd)
|
data/features/cli.feature
CHANGED
@@ -28,7 +28,7 @@ Feature: Command Line Processing
|
|
28
28
|
"""
|
29
29
|
When I run bin/texsc with "article.tex"
|
30
30
|
Then Exit code is not zero
|
31
|
-
And Stdout contains "& friiend
|
31
|
+
And Stdout contains "& friiend "
|
32
32
|
|
33
33
|
Scenario: Bad LaTeX with PWS can be spell checked
|
34
34
|
Given I have a "article.tex" file with content:
|
@@ -74,6 +74,17 @@ Feature: Command Line Processing
|
|
74
74
|
When I run bin/texsc with "--ignore nospell article.tex"
|
75
75
|
Then Exit code is zero
|
76
76
|
|
77
|
+
Scenario: Bad LaTeX with complex --ignore can be spell checked
|
78
|
+
Given I have a "article.tex" file with content:
|
79
|
+
"""
|
80
|
+
\documentclass{article}
|
81
|
+
\begin{document}
|
82
|
+
How are you, my dear \nospell[friiend]{friiend}{friiend}?
|
83
|
+
\end{document}
|
84
|
+
"""
|
85
|
+
When I run bin/texsc with "--ignore nospell:opp article.tex"
|
86
|
+
Then Exit code is zero
|
87
|
+
|
77
88
|
Scenario: Bad LaTeX with too short words can be spell checked
|
78
89
|
Given I have a "article.tex" file with content:
|
79
90
|
"""
|
data/texsc.gemspec
CHANGED
@@ -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.
|
35
|
+
s.version = '0.3.0'
|
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,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: texsc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yegor Bugayenko
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-08-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: backtrace
|