Skip to content

Commit d821170

Browse files
committed
git_override
1 parent f623bf8 commit d821170

2 files changed

Lines changed: 21 additions & 6 deletions

File tree

‎.github/workflows/build-bazel.yml‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@ jobs:
66
bazel:
77
runs-on: ${{ matrix.os }}
88
strategy:
9+
fail-fast: false
910
matrix:
10-
os: [macos-latest]
11+
os: [macos-latest, ubuntu-latest, windows-latest]
1112

1213
steps:
1314
- uses: actions/checkout@v4
@@ -16,10 +17,10 @@ jobs:
1617

1718
- name: bazel clean
1819
run: bazel clean
19-
20+
2021
- name: build bazel
2122
run: bazel build //...
22-
23+
2324
- name: test all
2425
run: bazel test --test_output=all //...
2526

‎MODULE.bazel‎

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,22 @@ bazel_dep(
2525
version = "0.2.5",
2626
)
2727

28-
local_cuda = use_extension("@rules_cuda//cuda:extensions.bzl", "toolchain")
29-
local_cuda.local_toolchain(
28+
# Override the module with the latest rules_cuda
29+
git_override(
30+
module_name = "rules_cuda",
31+
remote = "https://github.com/bazel-contrib/rules_cuda.git",
32+
commit = "3692ecb",
33+
)
34+
35+
# Load the extension
36+
cuda = use_extension("@rules_cuda//cuda:extensions.bzl", "toolchain")
37+
cuda.toolkit(
38+
name = "cuda",
3039
toolkit_path = "",
3140
)
32-
use_repo(local_cuda, "local_cuda")
41+
42+
# Use 'cuda' as the repository name
43+
# use_repo(cuda, "cuda")
44+
45+
# Alias local_cuda
46+
use_repo(cuda, local_cuda = "cuda")

0 commit comments

Comments
 (0)