• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kubernetes-sigs / kubebuilder / 15232042200

24 May 2025 11:38PM UTC coverage: 71.57% (-1.5%) from 73.023%
15232042200

push

github

web-flow
📖 Update the docs with release v4.6.0 (#4822)

* chore: simplify test variable declarations for CLI tests

Replaced redundant multi-line `var` blocks with single-line declarations in
`version_test.go` and `completion_test.go`. This reduces visual noise and aligns
with idiomatic Go style for concise test setup.

* chore: improve readability of test case for alternative delimiters

Reformatted the inline struct definition in `scaffold_test.go` to a multi-line
layout.

* chore: add gofumpt to golangci-lint configuration

Enabled the `gofumpt` linter in `.golangci.yml` to enforce stricter formatting rules
and ensure consistency with gofumpt standards across the codebase.

* :book: bump sigs.k8s.io/kubebuilder/v4

Bumps [sigs.k8s.io/kubebuilder/v4](https://github.com/kubernetes-sigs/kubebuilder) from 4.5.1 to 4.5.2.
- [Release notes](https://github.com/kubernetes-sigs/kubebuilder/releases)
- [Changelog](https://github.com/kubernetes-sigs/kubebuilder/blob/master/RELEASE.md)
- [Commits](https://github.com/kubernetes-sigs/kubebuilder/compare/v4.5.1...v4.5.2)

---
updated-dependencies:
- dependency-name: sigs.k8s.io/kubebuilder/v4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* chore: unify import alias for network-policy

Replaces import alias `network_policy` with `networkpolicy` to follow Go naming conventions.

* chore: normalize error messages and wrap errors using %w

- Use %w consistently in fmt.Errorf for proper error wrapping
- Normalize error message casing for consistency
- Adjust tests to reflect updated error strings

* chore: normalize error messages and wrap errors using %w

- Use %w consistently in fmt.Errorf for proper error wrapping

* chore: normalize error messages and wrap errors using %w

- Use %w consistently in fmt.Errorf for proper error wrapping

* 🌱 (chore): wrap errors with `%w` and normalize formatting in `kustomize/v2`

Replaced uses of `%v... (continued)

66 of 297 new or added lines in 17 files covered. (22.22%)

34 existing lines in 7 files now uncovered.

2311 of 3229 relevant lines covered (71.57%)

16.53 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

90.0
/pkg/plugin/util/exec.go
1
/*
2
Copyright 2020 The Kubernetes Authors.
3

4
Licensed under the Apache License, Version 2.0 (the "License");
5
you may not use this file except in compliance with the License.
6
You may obtain a copy of the License at
7

8
    http://www.apache.org/licenses/LICENSE-2.0
9

10
Unless required by applicable law or agreed to in writing, software
11
distributed under the License is distributed on an "AS IS" BASIS,
12
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
See the License for the specific language governing permissions and
14
limitations under the License.
15
*/
16

17
package util
18

19
import (
20
        "fmt"
21
        "os"
22
        "os/exec"
23
        "strings"
24

25
        log "github.com/sirupsen/logrus"
26
)
27

28
// RunCmd prints the provided message and command and then executes it binding stdout and stderr
29
func RunCmd(msg, cmd string, args ...string) error {
1✔
30
        c := exec.Command(cmd, args...) //nolint:gosec
1✔
31
        c.Stdout = os.Stdout
1✔
32
        c.Stderr = os.Stderr
1✔
33
        log.Println(msg + ":\n$ " + strings.Join(c.Args, " "))
1✔
34

1✔
35
        if err := c.Run(); err != nil {
2✔
36
                return fmt.Errorf("error running %q: %w", cmd, err)
1✔
37
        }
1✔
38

NEW
39
        return nil
×
40
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc