Skip to content

Commit bb8a648

Browse files
feat: Rollout crate/typos for operators (#818)
* chore: Generated commit to update templated files since the last template run up to stackabletech/operator-templating@0f53eec Reference-to: stackabletech/operator-templating@0f53eec (feat: Rollout crate/typos for operators) * chore: Add typos.toml and fix spelling findings --------- Co-authored-by: Maxi Wittich <maximilian.wittich@stackable.tech>
1 parent 12cc9e0 commit bb8a648

6 files changed

Lines changed: 60 additions & 5 deletions

File tree

‎.pre-commit-config.yaml‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,19 @@ default_language_version:
77
node: system
88

99
repos:
10+
# The word lists live in a per-repo `typos.toml`, which is not templated.
11+
# typos has no layered configuration (https://github.com/crate-ci/typos/issues/193).
12+
# A templated config can currently not be extended locally.
13+
- repo: https://github.com/crate-ci/typos
14+
rev: 00f422f3b19c57bc6338715ebfe3316d38768461 # v1.50.3
15+
hooks:
16+
- id: typos
17+
# Drop the upstream default `--write-changes` so the hook only
18+
# reports failures instead of writing changes.
19+
# Keep `--force-exclude` so the excludes in typos.toml still
20+
# apply to the paths prek passes in.
21+
args: ["--force-exclude"]
22+
1023
- repo: https://github.com/pre-commit/pre-commit-hooks
1124
rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # 6.0.0
1225
hooks:

‎docs/modules/hbase/pages/getting_started/first_steps.adoc‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ include::example$getting_started/hbase.yaml[]
7575

7676
To test the cluster, use the REST API to check its version and status, and to create and inspect a new table.
7777
Use Phoenix to create, populate and query a second new table, before listing all non-system tables in HBase.
78-
These actions wil be carried out from one of the HBase components, the REST server.
78+
These actions will be carried out from one of the HBase components, the REST server.
7979

8080
First, check the cluster version with this callout:
8181

‎tests/templates/kuttl/kerberos/02-create-kerberos-secretclass.yaml.j2‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ metadata:
4747
name: secret-operator-keytab
4848
data:
4949
{% if test_scenario['values']['kerberos-backend'] == 'mit' %}
50-
# To create keytab. When promted enter password asdf
50+
# To create keytab. When prompted enter password asdf
5151
# cat | ktutil << 'EOF'
5252
# list
5353
# add_entry -password -p stackable-secret-operator@CLUSTER.LOCAL -k 1 -e aes256-cts-hmac-sha384-192

‎tests/templates/kuttl/opa/02-create-kerberos-secretclass.yaml.j2‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ kind: Secret
2828
metadata:
2929
name: secret-operator-keytab
3030
data:
31-
# To create keytab. When promted enter password asdf
31+
# To create keytab. When prompted enter password asdf
3232
# cat | ktutil << 'EOF'
3333
# list
3434
# add_entry -password -p stackable-secret-operator@CLUSTER.LOCAL -k 1 -e aes256-cts-hmac-sha384-192

‎tests/templates/kuttl/shutdown/50-assert.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
# This test works as follows:
33
# - given
44
# - an HBase cluster with two region servers (0 and 1)
5-
# - create a table + column familiy with 15 regions
5+
# - create a table + column family with 15 regions
66
# - where region server 0 has some regions assigned to it
7-
# - restart server 0 (the region mover is triggerred by the shutdown)
7+
# - restart server 0 (the region mover is triggered by the shutdown)
88
# - assert that server 1 now hosts all 15 regions
99
apiVersion: kuttl.dev/v1beta1
1010
kind: TestAssert

‎typos.toml‎

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Configuration for typos (https://github.com/crate-ci/typos), run via the prek
2+
# hook in .pre-commit-config.yaml.
3+
4+
[files]
5+
# Bare `typos` skips hidden dirs by default, but prek passes explicit paths and
6+
# so does check them. Turn it off so both agree.
7+
ignore-hidden = false
8+
9+
extend-exclude = [
10+
# Ignore `.git`, which the above `ignore-hidden = false` would otherwise pull in.
11+
".git/",
12+
# Generated by crate2nix (`make regenerate-nix`). Already skipped by the prek
13+
# top-level `exclude`; listed here so a bare `typos` run agrees.
14+
"Cargo.nix",
15+
# Generated by `make regenerate-charts` from the Rust doc comments, which are
16+
# checked at their source. The rest is Kubernetes' own schema documentation.
17+
"extra/crds.yaml",
18+
]
19+
20+
[default]
21+
# typos has no native suppression directive
22+
# (https://github.com/crate-ci/typos/issues/316), so these regexes provide one.
23+
# A marker must sit in a comment: after `#`, `//` or `;` (free text may follow),
24+
# or inside a closed `<!-- -->`, `/* */` or `{# #}` (free text may precede the
25+
# closer). An unterminated `typos:ignore-block-start` suppresses nothing.
26+
#
27+
# Use one of the following when the word is correct at one place but would still be a typo elsewhere:
28+
#
29+
# # typos:ignore-line at the end of the line it applies to
30+
# # typos:ignore-next-line on its own line, above the offending line
31+
# # typos:ignore-block-start / typos:ignore-block-end around a block
32+
extend-ignore-re = [
33+
'(?Rm)^.*?(?:(?:^|[^{])(?:#|//|;)[ \t]*typos:ignore-line\b.*|(?:<!--[ \t]*typos:ignore-line\b.*?-->|/\*[ \t]*typos:ignore-line\b.*?\*/|\{#[ \t]*typos:ignore-line\b.*?#\})[ \t]*)$',
34+
'(?Rm)^[ \t]*(?:(?:#|//|;)[ \t]*typos:ignore-next-line\b.*|(?:<!--[ \t]*typos:ignore-next-line\b.*?-->|/\*[ \t]*typos:ignore-next-line\b.*?\*/|\{#[ \t]*typos:ignore-next-line\b.*?#\})[ \t]*)\r?\n.*$',
35+
'(?ms)(?:(?:^|[^{])(?:#|//|;)[ \t]*typos:ignore-block-start\b|<!--[ \t]*typos:ignore-block-start\b[^\n]*?-->|/\*[ \t]*typos:ignore-block-start\b[^\n]*?\*/|\{#[ \t]*typos:ignore-block-start\b[^\n]*?#\}).*?(?:(?:^|[^{])(?:#|//|;)[ \t]*typos:ignore-block-end\b|<!--[ \t]*typos:ignore-block-end\b[^\n]*?-->|/\*[ \t]*typos:ignore-block-end\b[^\n]*?\*/|\{#[ \t]*typos:ignore-block-end\b[^\n]*?#\})',
36+
]
37+
38+
# Before adding an entry in here, consider an in-place marker instead.
39+
# Every entry below gets a one-line comment saying what the word is.
40+
[default.extend-words]
41+
# Azure Kubernetes Service
42+
aks = "aks"

0 commit comments

Comments
 (0)