You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When walking through the files generated through kubebuilder, I found codes in some files are not well-aligned, for example in cmd/controller-manager/main.go:
import (
"flag"
"log"
// Import auth/gcp to connect to GKE clusters remotely
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
configlib "github.com/kubernetes-sigs/kubebuilder/pkg/config"
"github.com/kubernetes-sigs/kubebuilder/pkg/inject/run"
"github.com/kubernetes-sigs/kubebuilder/pkg/install"
"github.com/kubernetes-sigs/kubebuilder/pkg/signals"
extensionsv1beta1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1"
"example.com/pkg/inject"
"example.com/pkg/inject/args"
)
var installCRDs = flag.Bool("install-crds", true, "install the CRDs used by the controller as part of startup")
// Controller-manager main.
func main() {
flag.Parse()
stopCh := signals.SetupSignalHandler()
Of course a user can easily format the files via go fmt, but for better experience, I think we'd better
modify existing templates and the place to generate files, to ensure the generated codes are well-formated
or maybe we can exec go format for output files automatically
When walking through the files generated through
kubebuilder
, I found codes in some files are not well-aligned, for example incmd/controller-manager/main.go
:Of course a user can easily format the files via
go fmt
, but for better experience, I think we'd bettergo format
for output files automatically@pwittrock WDYT?
The text was updated successfully, but these errors were encountered: