Skip to content

Commit d5af35e

Browse files
committed
ci: ensure that typos are handles during CI
1 parent 5e69223 commit d5af35e

File tree

9 files changed

+25
-9
lines changed

9 files changed

+25
-9
lines changed

.pre-commit-config.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
# Pre-Commit hooks
22
# See: https://pre-commit.com/hooks.html
33
repos:
4+
- repo: https://github.com/crate-ci/typos
5+
rev: v1.42.0
6+
hooks:
7+
- id: typos
8+
49
- repo: https://github.com/pre-commit/pre-commit-hooks
510
rev: v5.0.0
611
hooks:

.typos.toml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[default.extend-identifiers]
2+
# Proper names - do not correct
3+
Mno-hime = "Mno-hime"
4+
5+
[default.extend-words]
6+
# Proper names - do not correct
7+
hime = "hime"
8+
McClory = "McClory"
9+
mcclory = "mcclory"
10+
Clory = "Clory"
11+
repositor = "repositor"

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
114114
### Added
115115

116116
- Added `--force` parameter to the Auth command to be used in conjunction with `--token` to refresh tokens without interactive prompts i.e automatic.
117-
- Added `--force` parameter to the Tokens refresh command to automaticlly refresh without an interactive prompt.
117+
- Added `--force` parameter to the Tokens refresh command to automatically refresh without an interactive prompt.
118118

119119
## [1.8.5] - 2025-10-16
120120

cloudsmith_cli/cli/commands/metrics/entitlements.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def _print_metrics_table(opts, data):
7575
type=str,
7676
required=False,
7777
help=(
78-
"A comma seperated list of entitlement token identifiers (i.e. slug_perm) or "
78+
"A comma separated list of entitlement token identifiers (i.e. slug_perm) or "
7979
"token secrets. If a list is not specified then all entitlement tokens will "
8080
"be included for a given namespace or repository."
8181
),

cloudsmith_cli/cli/commands/metrics/packages.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ def _print_metrics_table(opts, data):
7474
type=str,
7575
required=False,
7676
help=(
77-
"A comma seperated list of package identifiers (i.e. slug_perm). "
77+
"A comma separated list of package identifiers (i.e. slug_perm). "
7878
"If a list is not specified then all package will be included for "
7979
"a given repository."
8080
),

cloudsmith_cli/cli/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ def get_storage_name_for(cls, section_name):
9595

9696
@classmethod
9797
def get_default_filepath(cls):
98-
"""Get the default filepath for the configuratin file."""
98+
"""Get the default filepath for the configuration file."""
9999
if not cls.config_files:
100100
return None
101101
if not cls.config_searchpath:

cloudsmith_cli/cli/tests/commands/test_repos.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@ def parse_table(output):
3535
Results: 1 repository visible
3636
```
3737
"""
38-
seperator = "|"
38+
separator = "|"
3939
column_headers = []
4040
row_values = []
4141

4242
for line in output.split("\n"):
43-
if seperator in line:
44-
raw_values = [raw_value.strip() for raw_value in line.split(seperator)]
43+
if separator in line:
44+
raw_values = [raw_value.strip() for raw_value in line.split(separator)]
4545
if not column_headers:
4646
# If we don't have keys yet, then this must be the column headers
4747
column_headers = raw_values

cloudsmith_cli/core/ratelimits.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def from_dict(cls, data):
4040
info.remaining = int(data["remaining"])
4141
if "reset" in data:
4242
info.reset = datetime.datetime.utcfromtimestamp(int(data["reset"]))
43-
if "throtted" in data:
43+
if "throttled" in data:
4444
info.throttled = bool(data["throttled"])
4545
else:
4646
info.throttled = info.remaining == 0

cloudsmith_cli/core/tests/test_init.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def mocked_update_refresh_attempted_at():
5858

5959
class TestInitialiseApi:
6060
def setup_class(cls): # pylint: disable=no-self-argument
61-
# For the purposes of these tests, we need to explcitly call set_default(None) at the
61+
# For the purposes of these tests, we need to explicitly call set_default(None) at the
6262
# outset because other tests in the suite may have called initialise_api() already.
6363
# Resetting Configuration._default to None here effectively reverts the
6464
# Configuration class to its vanilla, unmodified behaviour/state.

0 commit comments

Comments
 (0)