Skip to content

Commit 9ed00b2

Browse files
committed
Clean-up the config for 'typos'
"Identifiers" are a grouping of "words", which means I can use a regex on "words" to exclude TLAs from consideration. The newer version of 'typos' also seems to have picked up knowledge of some Go libraries.
1 parent a131950 commit 9ed00b2

File tree

2 files changed

+30
-23
lines changed

2 files changed

+30
-23
lines changed

.typos.toml

Lines changed: 29 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,38 @@
1-
# Configure 'typos' to reduce false positives.
2-
# For more information, see <https://github.com/crate-ci/typos>.
1+
# ***************************************************************
2+
#
3+
# Copyright (C) 2026, Pelican Project, Morgridge Institute for Research
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License"); you
6+
# may not use this file except in compliance with the License. You may
7+
# obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
#
17+
# ***************************************************************
318

19+
# See https://github.com/crate-ci/typos for more information
420
[default]
5-
extend-ignore-identifiers-re = [
6-
## Ignore TLAs. Two and three letter acronyms are not worth fixing.
7-
"^[A-Za-z]{2,3}$",
8-
## Ignore lotman's use of 'ded' for 'dedicated'.
9-
"^ded[A-Z]",
10-
"^[a-z]+Ded",
11-
## Ignore server_utils's use of 'dne' for 'does not exist'.
12-
"_dne$",
21+
extend-ignore-words-re = [
22+
# Two- and three-letter "words" are common in code
23+
"^[[:alpha:]]{2,3}$",
1324
]
1425

1526
[default.extend-identifiers]
16-
## The 'cipher' library uses "Encrypter"; 'typos' prefers "Encryptor".
17-
NewCFBEncrypter = "NewCFBEncrypter"
18-
## HTCondor's daemon names follow the usual "{word} + 'd'" convention.
19-
StartdAttrs = "StartdAttrs"
27+
# HTCondor's daemon names follow the usual "{word} + 'd'" convention
2028
condor_startd = "condor_startd"
21-
STARTD = "STARTD"
2229
Startd = "Startd"
30+
STARTD = "STARTD"
31+
StartdAttrs = "StartdAttrs"
2332

24-
[files]
25-
extend-exclude = [
26-
## Ignore configuration files and the like.
27-
"go.mod",
28-
"xrootd/resources/osdf-authfile",
29-
## Ignore this script because of its inline certificates.
30-
"github_scripts/osx_install.sh",
33+
[type.xrootd-metrics]
34+
extend-glob = ["xrootd_metrics.go"]
35+
extend-ignore-words-re = [
36+
# xrootd_metrics.go uses 'toal' as part of XRootD metric field names
37+
"toal",
3138
]

github_scripts/osx_install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ set -ex
2424
brew install minio ninja coreutils
2525

2626
# Attempted fix to install xrootd-s3-http, which relies on a dependency (nlohmann-json)
27-
# that requres cmake 3.5...4.0. The version pointed at here is the highest 3.X at the time
27+
# that requires cmake 3.5...4.0. The version pointed at here is the highest 3.X at the time
2828
# of writing (2025-09-22).
2929
# Install CMake 3.31.8 manually, since Homebrew does not provide it.
3030
CMAKE_VERSION=3.31.8

0 commit comments

Comments
 (0)