-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathsdk.bzl
More file actions
44 lines (40 loc) · 996 Bytes
/
sdk.bzl
File metadata and controls
44 lines (40 loc) · 996 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
load(
"@bazelruby_rules_ruby//ruby/private/toolchains:ruby_runtime.bzl",
_ruby_runtime = "ruby_runtime",
)
def rules_ruby_select_sdk(version = "host"):
"""Registers ruby toolchains in the WORKSPACE file."""
supported_versions = [
"host",
"2.5.8",
"2.5.9",
"2.6.3",
"2.6.4",
"2.6.5",
"2.6.6",
"2.6.7",
"2.6.8",
"2.6.9",
"2.7.1",
"2.7.2",
"2.7.3",
"2.7.4",
"2.7.5",
"3.0.0",
"3.0.1",
"3.0.2",
"3.0.3",
"3.1.0",
"3.1.1",
"3.1.2",
]
if version in supported_versions:
_ruby_runtime(
name = "org_ruby_lang_ruby_toolchain",
version = version,
)
else:
fail("rules_ruby_select_sdk: unsupported ruby version '%s' not in '%s'" % (version, supported_versions))
native.register_toolchains(
"@org_ruby_lang_ruby_toolchain//:toolchain",
)