Skip to content

Instantly share code, notes, and snippets.

@abutcher
Created April 22, 2020 14:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abutcher/342e466067977d7cbcda15e5cd8bd756 to your computer and use it in GitHub Desktop.
Save abutcher/342e466067977d7cbcda15e5cd8bd756 to your computer and use it in GitHub Desktop.
hive (master)  make
gofmt -w -s pkg contrib
go vet -mod=vendor ./pkg/... ./cmd/... ./contrib/...
cd v1alpha1apiserver && go vet -mod=vendor ./cmd/... ./pkg/...
/home/abutcher/go/src/github.com/openshift/hive/v1alpha1apiserver
go install -mod=vendor k8s.io/code-generator/cmd/deepcopy-gen
go install -mod=vendor k8s.io/code-generator/cmd/conversion-gen
go install -mod=vendor k8s.io/code-generator/cmd/defaulter-gen
go install -mod=vendor k8s.io/code-generator/cmd/client-gen
go install -mod=vendor sigs.k8s.io/controller-tools/cmd/controller-gen
go install -mod=vendor github.com/jteeuwen/go-bindata/go-bindata
go install -mod=vendor github.com/golang/mock/mockgen
go install -mod=vendor golang.org/x/lint/golint
go install -mod=vendor github.com/golangci/golangci-lint/cmd/golangci-lint
GOFLAGS=-mod=vendor go generate ./pkg/... ./cmd/...
cd v1alpha1apiserver && GOFLAGS=-mod=vendor go generate ./pkg/... ./cmd/...
/home/abutcher/go/src/github.com/openshift/hive/v1alpha1apiserver
hack/update-bindata.sh
hack/verify-generated.sh
make[1]: Entering directory '/home/abutcher/go/src/github.com/openshift/hive'
go install -mod=vendor k8s.io/code-generator/cmd/deepcopy-gen
go install -mod=vendor k8s.io/code-generator/cmd/conversion-gen
go install -mod=vendor k8s.io/code-generator/cmd/defaulter-gen
go install -mod=vendor k8s.io/code-generator/cmd/client-gen
go install -mod=vendor sigs.k8s.io/controller-tools/cmd/controller-gen
go install -mod=vendor github.com/jteeuwen/go-bindata/go-bindata
go install -mod=vendor github.com/golang/mock/mockgen
go install -mod=vendor golang.org/x/lint/golint
go install -mod=vendor github.com/golangci/golangci-lint/cmd/golangci-lint
GOFLAGS=-mod=vendor go generate ./pkg/... ./cmd/...
cd v1alpha1apiserver && GOFLAGS=-mod=vendor go generate ./pkg/... ./cmd/...
/home/abutcher/go/src/github.com/openshift/hive/v1alpha1apiserver
hack/update-bindata.sh
make[1]: Leaving directory '/home/abutcher/go/src/github.com/openshift/hive'
make[1]: Entering directory '/home/abutcher/go/src/github.com/openshift/hive'
go install -mod=vendor k8s.io/code-generator/cmd/deepcopy-gen
go install -mod=vendor k8s.io/code-generator/cmd/conversion-gen
go install -mod=vendor k8s.io/code-generator/cmd/defaulter-gen
go install -mod=vendor k8s.io/code-generator/cmd/client-gen
go install -mod=vendor sigs.k8s.io/controller-tools/cmd/controller-gen
go install -mod=vendor github.com/jteeuwen/go-bindata/go-bindata
go install -mod=vendor github.com/golang/mock/mockgen
go install -mod=vendor golang.org/x/lint/golint
go install -mod=vendor github.com/golangci/golangci-lint/cmd/golangci-lint
controller-gen crd paths=./pkg/apis/hive
Error: go [-e -json -compiled=true -test=false -export=false -deps=true -find=false -tags ignore_autogenerated -- ./pkg/apis/hive]: exit status 1: go: github.
com/openshift/api@v3.9.1-0.20191111211345-a27ff30ebf09+incompatible: invalid pseudo-version: preceding tag (v3.9.0) not found
Usage:
controller-gen [flags]
Examples:
# Generate RBAC manifests and crds for all types under apis/,
# outputting crds to /tmp/crds and everything else to stdout
controller-gen rbac:roleName=<role name> crd paths=./apis/... output:crd:dir=/tmp/crds output:stdout
# Generate deepcopy/runtime.Object implementations for a particular file
controller-gen object paths=./apis/v1beta1/some_types.go
# Generate OpenAPI v3 schemas for API packages and merge them into existing CRD manifests
controller-gen schemapatch:manifests=./manifests output:dir=./manifests paths=./pkg/apis/...
# Run all the generators for a given project
controller-gen paths=./apis/...
# Explain the markers for generating CRDs, and their arguments
controller-gen crd -ww
Flags:
-h, --detailed-help count print out more detailed help
(up to -hhh for the most detailed output, or -hhhh for json output)
--help print out usage and a summary of options
--version show version
-w, --which-markers count print out all markers available with the requested generators
(up to -www for the most detailed output, or -wwww for json output)
Options
generators
+webhook package generates (partial) {Mutating,Validating}We
bhookConfiguration objects.
+schemapatch:manifests=<string>[,maxDescLen=<int>] package patches existing CRDs with new schemata.
+rbac:roleName=<string> package generates ClusterRole objects.
+object[:headerFile=<string>][,year=<string>] package generates code containing DeepCopy, DeepCop
yInto, and DeepCopyObject method implementations.
+crd[:crdVersions=<[]string>][,maxDescLen=<int>][,preserveUnknownFields=<bool>][,trivialVersions=<bool>] package generates CustomResourceDefinition objects.
generic
+paths=<[]string> package represents paths and go-style path patterns to use as package roots.
output rules (optionally as output:<generator>:...)
+output:artifacts[:code=<string>],config=<string> package outputs artifacts to different locations, depending on whether they're package-associated or not.
+output:dir=<string> package outputs each artifact to the given directory, regardless of if it's package-associated or not.
+output:none package skips outputting anything.
+output:stdout package outputs everything to standard-out, with no separation.
run `controller-gen crd paths=./pkg/apis/hive -w` to see all available markers, or `controller-gen crd paths=./pkg/apis/hive -h` for usage
make[1]: *** [Makefile:165: crd] Error 1
make[1]: Leaving directory '/home/abutcher/go/src/github.com/openshift/hive'
make: *** [Makefile:217: verify-generated] Error 2
hive (master) 
hive (master) 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment