diff --git a/.codespellrc b/.codespellrc new file mode 100644 index 00000000..be11f83d --- /dev/null +++ b/.codespellrc @@ -0,0 +1,7 @@ +[codespell] +# Ref: https://github.com/codespell-project/codespell#using-a-config-file +skip = .git,.git-meta,.gitignore,.gitattributes,.*cache,go.sum,.codespellrc +check-hidden = true +# Do not "fix" URLs: a typo in a URL is still the working link +ignore-regex = https?://\S+ +# ignore-words-list = diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml new file mode 100644 index 00000000..9458b0c8 --- /dev/null +++ b/.github/workflows/codespell.yml @@ -0,0 +1,23 @@ +# Codespell configuration is within .codespellrc +--- +name: Codespell + +on: + push: + branches: [master] + pull_request: + branches: [master] + +permissions: + contents: read + +jobs: + codespell: + name: Check for spelling errors + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v6 + - name: Codespell + uses: codespell-project/actions-codespell@8f01853be192eb0f849a5c7d721450e7a467c579 # v2.2 diff --git a/README.md b/README.md index f3bcbe4b..5759b71a 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ The required components of a system that supports CEL are: * An evaluator library that takes the binary format in the context and produces a result, usually a Boolean. -For use cases which require persistence or cross-process communcation, it is +For use cases which require persistence or cross-process communication, it is highly recommended to serialize the type-checked expression as a protocol buffer. The CEL team will maintains canonical protocol buffers for ASTs and will keep these versions identical and wire-compatible in perpetuity: diff --git a/doc/intro.md b/doc/intro.md index 61354fd8..0f46f3cc 100644 --- a/doc/intro.md +++ b/doc/intro.md @@ -35,7 +35,7 @@ matches(account.phone_number, "[0-9-]+") // true if number matches regexp ``` CEL expressions support most operators and functions one would expect when -working with protocol buffers: boolean operators, relations, arithmetics on +working with protocol buffers: boolean operators, relations, arithmetic on numbers, string and byte string operations, and operations to deal with lists and maps. The full reference of standard operations is described in the [language definition](langdef.md#standard). Note that applications of CEL may add diff --git a/doc/langdef.md b/doc/langdef.md index bcce828c..94bade14 100644 --- a/doc/langdef.md +++ b/doc/langdef.md @@ -398,7 +398,7 @@ represented during static type checking. A CEL implementation can add new types to the language. These types will be given names in the same namespace as the other types, but will have no special support in the language syntax. The only way to construct or use values of these -abstract types is through functions which the implementor must also provide. +abstract types is through functions which the implementer must also provide. Commonly, an abstract type will have a representation as a protocol buffer, so that it can be stored or transmitted across a network. In this case, the diff --git a/proto/cel/expr/syntax.proto b/proto/cel/expr/syntax.proto index 00635e66..f977aabf 100644 --- a/proto/cel/expr/syntax.proto +++ b/proto/cel/expr/syntax.proto @@ -102,7 +102,7 @@ message Expr { // A list creation expression. // - // Lists may either be homogenous, e.g. `[1, 2, 3]`, or heterogeneous, e.g. + // Lists may either be homogeneous, e.g. `[1, 2, 3]`, or heterogeneous, e.g. // `dyn([1, 'hello', 2.0])` message CreateList { // The elements part of the list. diff --git a/tests/simple/testdata/macros.textproto b/tests/simple/testdata/macros.textproto index 26a201fa..e3fbe2c0 100644 --- a/tests/simple/testdata/macros.textproto +++ b/tests/simple/testdata/macros.textproto @@ -29,7 +29,7 @@ section { } test { name: "list_elem_type_exhaustive" - description: "Exists filter is never true, but heterogenous equality ensure the result is false." + description: "Exists filter is never true, but heterogeneous equality ensure the result is false." expr: "[1, 'foo', 3].exists(e, e == '10')" value: { bool_value: false } }