mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-11 17:16:18 +00:00
hack/update-vendor.sh
This commit is contained in:
14
vendor/github.com/bazelbuild/buildtools/buildozer/main.go
generated
vendored
14
vendor/github.com/bazelbuild/buildtools/buildozer/main.go
generated
vendored
@@ -20,11 +20,16 @@ import (
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"github.com/bazelbuild/buildtools/build"
|
||||
"github.com/bazelbuild/buildtools/edit"
|
||||
"github.com/bazelbuild/buildtools/tables"
|
||||
)
|
||||
|
||||
var (
|
||||
buildVersion = "redacted"
|
||||
buildScmRevision = "redacted"
|
||||
|
||||
version = flag.Bool("version", false, "Print the version of buildozer")
|
||||
stdout = flag.Bool("stdout", false, "write changed BUILD file to stdout")
|
||||
buildifier = flag.String("buildifier", "", "format output using a specific buildifier binary. If empty, use built-in formatter")
|
||||
parallelism = flag.Int("P", 0, "number of cores to use for concurrent actions")
|
||||
@@ -61,6 +66,12 @@ func stringList(name, help string) func() []string {
|
||||
func main() {
|
||||
flag.Parse()
|
||||
|
||||
if *version {
|
||||
fmt.Printf("buildozer version: %s \n", buildVersion)
|
||||
fmt.Printf("buildozer scm revision: %s \n", buildScmRevision)
|
||||
os.Exit(0)
|
||||
}
|
||||
|
||||
if *tablesPath != "" {
|
||||
if err := tables.ParseAndUpdateJSONDefinitions(*tablesPath, false); err != nil {
|
||||
fmt.Fprintf(os.Stderr, "buildifier: failed to parse %s for -tables: %s\n", *tablesPath, err)
|
||||
@@ -75,6 +86,9 @@ func main() {
|
||||
}
|
||||
}
|
||||
|
||||
if !(*shortenLabelsFlag) {
|
||||
build.DisableRewrites = []string{"label"}
|
||||
}
|
||||
edit.ShortenLabelsFlag = *shortenLabelsFlag
|
||||
edit.DeleteWithComments = *deleteWithComments
|
||||
opts := &edit.Options{
|
||||
|
||||
Reference in New Issue
Block a user