Skip to content

Commit 492dca3

Browse files
author
graham jenson
committed
fixing for review
1 parent d987f93 commit 492dca3

File tree

4 files changed

+7
-41
lines changed

4 files changed

+7
-41
lines changed

examples/simple_script/WORKSPACE

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,5 @@ bundle_install(
2727
name = "bundle",
2828
gemfile = "//:Gemfile",
2929
gemfile_lock = "//:Gemfile.lock",
30+
version = "2.0.2",
3031
)

ruby/private/bundle/bundle.bzl

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
load("//ruby/private:constants.bzl", "RULES_RUBY_WORKSPACE_NAME")
22

3-
_DEFAULT_VERSION = "2.0.2"
4-
5-
def install_bundler(ctx, interpreter, install_bundler, dest, version = _DEFAULT_VERSION):
3+
def install_bundler(ctx, interpreter, install_bundler, dest, version):
64
args = ["env", "-i", interpreter, install_bundler, version, dest]
75
environment = {"RUBYOPT": "--disable-gems"}
86

@@ -32,6 +30,7 @@ def bundle_install_impl(ctx):
3230
interpreter_path,
3331
"install_bundler.rb",
3432
"bundler",
33+
ctx.attr.version,
3534
)
3635

3736
bundler = Label("//:bundler/exe/bundler")
@@ -108,6 +107,9 @@ bundle_install = repository_rule(
108107
"gemfile_lock": attr.label(
109108
allow_single_file = True,
110109
),
110+
"version": attr.string(
111+
default = "2.0.2",
112+
),
111113
"gemspec": attr.label(
112114
allow_single_file = True,
113115
),

ruby/private/bundle/gem_install.bzl

Lines changed: 0 additions & 37 deletions
This file was deleted.

ruby/private/sdk.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def ruby_register_toolchains(version = "host"):
1313
version = version,
1414
)
1515
else:
16-
fail("unknown ruby version in `ruby_register_toolchains`")
16+
fail("unsupported ruby version in `ruby_register_toolchains`")
1717

1818
native.register_toolchains(
1919
"@org_ruby_lang_ruby_toolchain//:toolchain",

0 commit comments

Comments
 (0)