From 9d5be867e6ff32940eb1d8663647ace1f52b6207 Mon Sep 17 00:00:00 2001 From: David Fridrich Date: Mon, 15 Dec 2025 21:49:11 +0100 Subject: [PATCH] fix typos --- cmd/create_test.go | 2 +- cmd/delete_test.go | 4 ++-- cmd/deploy_test.go | 4 ++-- docs/reference/func_yaml.md | 2 +- pkg/functions/client_test.go | 6 +++--- pkg/functions/function.go | 2 +- pkg/oci/builder.go | 2 +- pkg/oci/python_builder.go | 2 +- pkg/s2i/assemblers.go | 2 +- pkg/scaffolding/scaffold.go | 6 +++--- schema/func_yaml-schema.json | 2 +- 11 files changed, 17 insertions(+), 17 deletions(-) diff --git a/cmd/create_test.go b/cmd/create_test.go index bb00c385fa..2bcefb2614 100644 --- a/cmd/create_test.go +++ b/cmd/create_test.go @@ -96,5 +96,5 @@ func TestCreate_ConfigOptional(t *testing.T) { } // Not failing is success. Config files or settings beyond what are - // automatically written to to the given config home are currently optional. + // automatically written to the given config home are currently optional. } diff --git a/cmd/delete_test.go b/cmd/delete_test.go index 26717085e4..93b0eb3bee 100644 --- a/cmd/delete_test.go +++ b/cmd/delete_test.go @@ -143,9 +143,9 @@ func TestDelete_Namespace(t *testing.T) { } } -// TestDelete_NamespaceFlagPriority ensures that even thought there is +// TestDelete_NamespaceFlagPriority ensures that even though there is // a deployed function the namespace flag takes precedence and essentially -// ignores the the function on disk +// ignores the function on disk func TestDelete_NamespaceFlagPriority(t *testing.T) { var ( root = FromTempDirectory(t) diff --git a/cmd/deploy_test.go b/cmd/deploy_test.go index 4ef8b0628d..70f10872b8 100644 --- a/cmd/deploy_test.go +++ b/cmd/deploy_test.go @@ -1756,8 +1756,8 @@ func TestDeploy_UnsetFlag(t *testing.T) { } } -// Test_ValidateBuilder tests that the bulder validation accepts the -// the set of known builders, and spot-checks an error is thrown for unknown. +// Test_ValidateBuilder tests that the builder validation accepts the +// set of known builders, and spot-checks an error is thrown for unknown. func Test_ValidateBuilder(t *testing.T) { for _, name := range KnownBuilders() { if err := ValidateBuilder(name); err != nil { diff --git a/docs/reference/func_yaml.md b/docs/reference/func_yaml.md index 358ef38969..6c0eabba13 100644 --- a/docs/reference/func_yaml.md +++ b/docs/reference/func_yaml.md @@ -19,7 +19,7 @@ The following fields are used in `func.yaml`. ### `build` -Specifies how to build the fuction. Possible values are "local" to build on your local +Specifies how to build the function. Possible values are "local" to build on your local computer, or "git" to build on the cluster by pulling function source code from a git repository. diff --git a/pkg/functions/client_test.go b/pkg/functions/client_test.go index 21a6725347..1ae6ea1558 100644 --- a/pkg/functions/client_test.go +++ b/pkg/functions/client_test.go @@ -167,7 +167,7 @@ func TestClient_New_RunDataDir(t *testing.T) { t.Fatal("The user's directive to explicitly allow .func in source control was not respected") } - // Ensure that in addition the the correctly formatted comment "# /.func", + // Ensure that in addition to the correctly formatted comment "# /.func", // it will work if the user omits the space: "#/.func" root, rm = Mktemp(t) defer rm() @@ -199,11 +199,11 @@ func TestClient_New_RunDataDir(t *testing.T) { // such as ensuring that files and directories with just the prefix are not // matched, that the user can use non-absolute ignores (no slash prefix), etc. // If this turns out to be necessary, we will need to add the test cases - // and have the implementation actually parse the file rather that simple + // and have the implementation actually parse the file rather than simple // line prefix checks. } -// TestClient_New_RuntimeRequired ensures that the the runtime is an expected value. +// TestClient_New_RuntimeRequired ensures that the runtime is an expected value. func TestClient_New_RuntimeRequired(t *testing.T) { // Create a root for the new function root := "testdata/example.com/testRuntimeRequired" diff --git a/pkg/functions/function.go b/pkg/functions/function.go index 4c4346f0c2..c6a2c28ad3 100644 --- a/pkg/functions/function.go +++ b/pkg/functions/function.go @@ -152,7 +152,7 @@ type BuildSpec struct { // in .func/built-image Image string `yaml:"-"` - // BaseImage defines an override for the function to be built upon (host bulder only) + // BaseImage defines an override for the function to be built upon (host builder only) BaseImage string `yaml:"baseImage,omitempty"` // Mounts used in build phase. This is useful in particular for paketo bindings. diff --git a/pkg/oci/builder.go b/pkg/oci/builder.go index 848a11417f..4e623cc216 100644 --- a/pkg/oci/builder.go +++ b/pkg/oci/builder.go @@ -253,7 +253,7 @@ func scaffold(job *buildJob) (err error) { return } err = scaffolding.Write( - job.buildDir(), // desintation for scaffolding + job.buildDir(), // destination for scaffolding job.function.Root, // source to be scaffolded job.function.Runtime, // scaffolding language to write job.function.Invoke, repo.FS()) diff --git a/pkg/oci/python_builder.go b/pkg/oci/python_builder.go index 4272590928..1f2027ba2b 100644 --- a/pkg/oci/python_builder.go +++ b/pkg/oci/python_builder.go @@ -84,7 +84,7 @@ func (b pythonBuilder) WriteShared(job buildJob) (layers []imageLayer, err error } // Install Dependencies of the current project into ./lib - // In the scaffolding direcotory. + // In the scaffolding directory. if job.verbose { fmt.Printf(".venv/bin/pip install . --target lib\n") } diff --git a/pkg/s2i/assemblers.go b/pkg/s2i/assemblers.go index 0461e0998b..b5b2b485bf 100644 --- a/pkg/s2i/assemblers.go +++ b/pkg/s2i/assemblers.go @@ -87,7 +87,7 @@ fi // PythonAssembler // // Adapted from /usr/libexec/s2i/assemble within the UBI-8 python-toolchain -// such that the the script executes from subdirectory .s2i/builds/last +// such that the script executes from subdirectory .s2i/builds/last // (where main resides) rather than the root, and indicates the main is // likewise in .s2i/builds/last/service/main.py via Procfile. See the comment // inline on line 50 of the script for where the directory change instruction diff --git a/pkg/scaffolding/scaffold.go b/pkg/scaffolding/scaffold.go index 42bf59eb71..5333e7fbdb 100644 --- a/pkg/scaffolding/scaffold.go +++ b/pkg/scaffolding/scaffold.go @@ -16,7 +16,7 @@ import ( // signature used by the function's source code and then writes the // appropriate scaffolding. // -// NOTE: Scaffoding is not per-template, because a template is merely an +// NOTE: Scaffolding is not per-template, because a template is merely an // example starting point for a Function implementation and should have no // bearing on the shape that function can eventually take. The language, // and optionally invocation hint (For cloudevents) are used for this. For @@ -27,8 +27,8 @@ import ( // out: the path to output scaffolding // src: the path to the source code to scaffold // runtime: the expected runtime of the target source code "go", "node" etc. -// invoke: the optional invocatin hint (default "http") -// fs: filesytem which contains scaffolding at '[runtime]/scaffolding' +// invoke: the optional invocation hint (default "http") +// fs: filesystem which contains scaffolding at '[runtime]/scaffolding' // (exclusive with 'repo') func Write(out, src, runtime, invoke string, fs filesystem.Filesystem) (err error) { // detect the signature of the source code in the given location, presuming diff --git a/schema/func_yaml-schema.json b/schema/func_yaml-schema.json index 9dd40200a8..eb8b637826 100644 --- a/schema/func_yaml-schema.json +++ b/schema/func_yaml-schema.json @@ -51,7 +51,7 @@ }, "baseImage": { "type": "string", - "description": "BaseImage defines an override for the function to be built upon (host bulder only)" + "description": "BaseImage defines an override for the function to be built upon (host builder only)" }, "volumes": { "items": {