diff options
author | David Benjamin <davidben@google.com> | 2024-05-30 15:27:55 -0400 |
---|---|---|
committer | Boringssl LUCI CQ <boringssl-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2024-05-30 21:21:43 +0000 |
commit | 261579f08b2f8aa7959670df1e928c1c305a632c (patch) | |
tree | a6d1e6f3fc2de7d9adaab77c44ea56cf6b9dea53 /util | |
parent | 9540c0452343e684f94515288880b6b35655f792 (diff) | |
download | boringssl-261579f08b2f8aa7959670df1e928c1c305a632c.zip boringssl-261579f08b2f8aa7959670df1e928c1c305a632c.tar.gz boringssl-261579f08b2f8aa7959670df1e928c1c305a632c.tar.bz2 |
Fix the indentation in gen/sources.bzl
It seems that some presubmit in the internal repository is now checking
such things. This also means that GN and Bazel don't quite have the same
syntax because they have different canonical indentations.
Change-Id: Ied7eb69669d1cb00550ff52ecb7a6a6a50501936
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/68947
Reviewed-by: Bob Beck <bbe@google.com>
Auto-Submit: David Benjamin <davidben@google.com>
Commit-Queue: David Benjamin <davidben@google.com>
Diffstat (limited to 'util')
-rw-r--r-- | util/pregenerate/build.go | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/util/pregenerate/build.go b/util/pregenerate/build.go index 57e83c8..7013945 100644 --- a/util/pregenerate/build.go +++ b/util/pregenerate/build.go @@ -219,7 +219,7 @@ func buildVariablesTask(targets map[string]build.Target, dst, comment string, wr func writeBazelVariable(b *bytes.Buffer, name string, val []string) { fmt.Fprintf(b, "\n%s = [\n", name) for _, v := range val { - fmt.Fprintf(b, " %q,\n", v) + fmt.Fprintf(b, " %q,\n", v) } fmt.Fprintf(b, "]\n") } @@ -245,8 +245,11 @@ func writeMakeVariable(b *bytes.Buffer, name string, val []string) { } func writeGNVariable(b *bytes.Buffer, name string, val []string) { - // Bazel and GN have the same syntax similar syntax. - writeBazelVariable(b, name, val) + fmt.Fprintf(b, "\n%s = [\n", name) + for _, v := range val { + fmt.Fprintf(b, " %q,\n", v) + } + fmt.Fprintf(b, "]\n") } func jsonTask(targets map[string]build.Target, dst string) Task { |