mirror of
https://github.com/openai/codex.git
synced 2026-09-13 11:47:17 +00:00
ci: run Windows argument-comment-lint via native Bazel
This commit is contained in:
18
.github/scripts/run-argument-comment-lint-bazel.sh
vendored
Executable file
18
.github/scripts/run-argument-comment-lint-bazel.sh
vendored
Executable file
@@ -0,0 +1,18 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
manual_rust_test_targets=()
|
||||
# Wildcard target patterns skip manual-tagged unit-test binaries, so resolve
|
||||
# them explicitly to keep Bazel lint coverage aligned with Cargo --all-targets.
|
||||
while IFS= read -r label; do
|
||||
manual_rust_test_targets+=("$label")
|
||||
done < <(bazel query 'kind("rust_test rule", attr(tags, manual, //codex-rs/...))')
|
||||
|
||||
./.github/scripts/run-bazel-ci.sh \
|
||||
-- \
|
||||
build \
|
||||
"$@" \
|
||||
-- \
|
||||
//codex-rs/... \
|
||||
"${manual_rust_test_targets[@]}"
|
||||
11
.github/scripts/run-bazel-ci.sh
vendored
11
.github/scripts/run-bazel-ci.sh
vendored
@@ -126,6 +126,17 @@ if [[ $remote_download_toplevel -eq 1 ]]; then
|
||||
post_config_bazel_args+=(--remote_download_toplevel)
|
||||
fi
|
||||
|
||||
if [[ -n "${BAZEL_REPO_CONTENTS_CACHE:-}" ]]; then
|
||||
# Windows self-hosted runners can run multiple Bazel jobs concurrently. Give
|
||||
# each job its own repo contents cache so they do not fight over the shared
|
||||
# path configured in `ci-windows`.
|
||||
post_config_bazel_args+=("--repo_contents_cache=${BAZEL_REPO_CONTENTS_CACHE}")
|
||||
fi
|
||||
|
||||
if [[ -n "${BAZEL_REPOSITORY_CACHE:-}" ]]; then
|
||||
post_config_bazel_args+=("--repository_cache=${BAZEL_REPOSITORY_CACHE}")
|
||||
fi
|
||||
|
||||
bazel_console_log="$(mktemp)"
|
||||
trap 'rm -f "$bazel_console_log"' EXIT
|
||||
|
||||
|
||||
Reference in New Issue
Block a user