Skip to content

Commit 75406a9

Browse files
committed
CLEANUP/MINOR: aspell: clarify what ignore means
1 parent 8684402 commit 75406a9

File tree

4 files changed

+7
-10
lines changed

4 files changed

+7
-10
lines changed

.aspell.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
mode: all
22
min_length: 3
3-
ignore:
4-
- '*_test.go'
3+
ignore_files:
4+
- '*test.go'
55
allowed:
66
- aspell
77
- repo

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ example
104104
```yaml
105105
mode: subject
106106
min_length: 3
107-
ignore:
107+
ignore_files:
108108
- go.mod
109109
- go.sum
110110
- '*test.go'

aspell/aspell.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import (
1717
type Aspell struct {
1818
Mode mode `yaml:"mode"`
1919
MinLength int `yaml:"min_length"`
20-
Ignore []string `yaml:"ignore"`
20+
IgnoreFiles []string `yaml:"ignore_files"`
2121
AllowedWords []string `yaml:"allowed"`
2222
HelpText string `yaml:"-"`
2323
}
@@ -126,7 +126,7 @@ func (a Aspell) Check(subjects []string, commitsFull []string, content []map[str
126126
for _, file := range content {
127127
for name, v := range file {
128128
nextFile := false
129-
for _, filter := range a.Ignore {
129+
for _, filter := range a.IgnoreFiles {
130130
if match.MatchFilter(name, filter) {
131131
// log.Println("File", name, "in ignore list")
132132
nextFile = true

aspell/new.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,7 @@ Add words to allowed list if its false positive`
5252
content example:
5353
mode: subject
5454
min_length: 3
55-
ignore:
56-
- go.mod
57-
- go.sum
58-
- '*test.go'
55+
ignore_files:
5956
- 'gen/*'
6057
allowed:
6158
- aspell
@@ -67,7 +64,7 @@ allowed:
6764
for _, file := range ignoreFiles {
6865
if _, err := os.Stat(file); err == nil {
6966
log.Printf("aspell: added %s to ignore list", file)
70-
aspell.Ignore = append(aspell.Ignore, file)
67+
aspell.IgnoreFiles = append(aspell.IgnoreFiles, file)
7168
}
7269
}
7370

0 commit comments

Comments
 (0)