mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-10-01 01:36:09 -04:00
fixup! bazel: add tidy and check
Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
parent
02c97fac03
commit
8679988b6c
10
.github/workflows/test-tidy.yml
vendored
10
.github/workflows/test-tidy.yml
vendored
@ -34,10 +34,6 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: bazelisk run //:tidy
|
run: bazelisk run //:tidy
|
||||||
|
|
||||||
- name: Run Bazel check
|
|
||||||
shell: bash
|
|
||||||
run: bazelisk run //:check
|
|
||||||
|
|
||||||
- name: Check if tidy made modifications
|
- name: Check if tidy made modifications
|
||||||
id: tidycheck
|
id: tidycheck
|
||||||
shell: bash
|
shell: bash
|
||||||
@ -52,9 +48,13 @@ jobs:
|
|||||||
${diff}
|
${diff}
|
||||||
\`\`\`
|
\`\`\`
|
||||||
EOF
|
EOF
|
||||||
echo "::error::The repo is not tidy. Please run 'bazel run bazel/ci:tidy' and commit the changes."
|
echo "::error::The repo is not tidy. Please run 'bazel run //:tidy' and commit the changes."
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
|
- name: Run Bazel check
|
||||||
|
shell: bash
|
||||||
|
run: bazelisk run //:check
|
||||||
|
|
||||||
# The following steps are only executed if the previous tidy check failed
|
# The following steps are only executed if the previous tidy check failed
|
||||||
# and the action runs on an renovat branche. In this case, we tidy all
|
# and the action runs on an renovat branche. In this case, we tidy all
|
||||||
# modules again and commit the changes, so the user doesn't need to do it.
|
# modules again and commit the changes, so the user doesn't need to do it.
|
||||||
|
@ -16,5 +16,6 @@ alias(
|
|||||||
actual = "//bazel/ci:check",
|
actual = "//bazel/ci:check",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# These magic Gazelle commands need to be in the top-level BUILD file.
|
||||||
# gazelle:map_kind go_test go_test //bazel/go:go_test.bzl
|
# gazelle:map_kind go_test go_test //bazel/go:go_test.bzl
|
||||||
# gazelle:prefix github.com/edgelesssys/constellation/v2
|
# gazelle:prefix github.com/edgelesssys/constellation/v2
|
||||||
|
@ -65,12 +65,12 @@ sh_template(
|
|||||||
multirun(
|
multirun(
|
||||||
name = "tidy",
|
name = "tidy",
|
||||||
commands = [
|
commands = [
|
||||||
# execute sequentially
|
|
||||||
":go_mod_tidy",
|
":go_mod_tidy",
|
||||||
":gazelle_update_repos",
|
":gazelle_update_repos",
|
||||||
":gazelle_generate",
|
":gazelle_generate",
|
||||||
":buildifier_fix",
|
":buildifier_fix",
|
||||||
],
|
],
|
||||||
|
jobs = 1, # execute sequentially
|
||||||
visibility = ["//visibility:public"],
|
visibility = ["//visibility:public"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
"""multirun_deps"""
|
"""multirun_deps"""
|
||||||
|
|
||||||
load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
|
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||||
|
|
||||||
def multirun_deps():
|
def multirun_deps():
|
||||||
git_repository(
|
http_archive(
|
||||||
name = "com_github_ash2k_bazel_tools",
|
name = "com_github_ash2k_bazel_tools",
|
||||||
commit = "4e045b9b4e3e613970ab68941b556a356239d433",
|
sha256 = "0ad31a16c9e48b01a1a11daf908227a6bf6106269187cccf7398625fea2ba45a",
|
||||||
remote = "https://github.com/ash2k/bazel-tools.git",
|
strip_prefix = "bazel-tools-4e045b9b4e3e613970ab68941b556a356239d433",
|
||||||
|
url = "https://github.com/ash2k/bazel-tools/archive/4e045b9b4e3e613970ab68941b556a356239d433.tar.gz",
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user