{"id":18542767,"url":"https://github.com/coinbase/rules_ruby","last_synced_at":"2025-10-15T18:08:46.858Z","repository":{"id":40187731,"uuid":"232436515","full_name":"coinbase/rules_ruby","owner":"coinbase","description":"Bazel Ruby Rules","archived":false,"fork":false,"pushed_at":"2023-08-19T00:43:06.000Z","size":509,"stargazers_count":26,"open_issues_count":11,"forks_count":16,"subscribers_count":20,"default_branch":"master","last_synced_at":"2025-02-17T08:43:50.781Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Starlark","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/coinbase.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-07T23:25:39.000Z","updated_at":"2024-11-10T18:38:03.000Z","dependencies_parsed_at":"2024-11-06T20:10:35.468Z","dependency_job_id":"a2eebad4-5eb4-4fac-aaf4-e2132b795400","html_url":"https://github.com/coinbase/rules_ruby","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/coinbase/rules_ruby","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Frules_ruby","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Frules_ruby/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Frules_ruby/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Frules_ruby/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/coinbase","download_url":"https://codeload.github.com/coinbase/rules_ruby/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Frules_ruby/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265802075,"owners_count":23830509,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T20:10:31.151Z","updated_at":"2025-10-15T18:08:41.820Z","avatar_url":"https://github.com/coinbase.png","language":"Starlark","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- TOC depthFrom:1 depthTo:6 withLinks:1 updateOnSave:1 orderedList:0 --\u003e\n\n* [Usage](#usage)\n  * [WORKSPACE File](#workspace-file)\n  * [BUILD.bazel files](#buildbazel-files)\n* [Rules](#rules)\n  * [rb_library](#rb_library)\n  * [rb_binary](#rb_binary)\n  * [rb_test](#rb_test)\n  * [rb_bundle](#rb_bundle)\n  * [rb_gem](#rb_gem)\n* [What's coming next](#whats-coming-next)\n* [Contributing](#contributing)\n  * [Setup](#setup)\n    * [OSX Setup Script](#os-setup-script)\n      * [Issues During Setup](#issues-during-setup)\n  * [Developing Rules](#developing-rules)\n  * [Running Tests](#running-tests)\n  * [Linter](#linter)\n* [Copyright](#copyright)\n\n\u003c!-- /TOC --\u003e\n\n### Build Status\n\n| Build | Status |\n|---------:\t|---------------------------------------------------------------------------------------------------------------------------------------------------\t|\n| CircleCI Master: \t| [![CircleCI](https://circleci.com/gh/coinbase/rules_ruby.svg?style=svg)](https://circleci.com/gh/coinbase/rules_ruby) \t|\n\n\n# Rules Ruby\n\nRuby rules for [Bazel](https://bazel.build).\n\n** Current Status:** *Work in progress.*\n\nNote: we have a short guide on [Building your first Ruby Project](https://github.com/coinbase/rules_ruby/wiki/Build-your-ruby-project) on the Wiki. We encourage you to check it out.\n\n## Usage\n\n### `WORKSPACE` File\n\nAdd `rules_ruby_dependencies` and `ruby_register_toolchains` into your `WORKSPACE` file.\n\n```python\n# To get the latest, grab the 'master' branch.\n\ngit_repository(\n    name = \"coinbase_rules_ruby\",\n    remote = \"https://github.com/coinbase/rules_ruby.git\",\n    branch = \"master\",\n)\n\nload(\n    \"@coinbase_rules_ruby//ruby:deps.bzl\",\n    \"ruby_register_toolchains\",\n    \"rules_ruby_dependencies\",\n)\n\nrules_ruby_dependencies()\n\nruby_register_toolchains()\n```\n\nNext, add any external Gem dependencies you may have via `rb_bundle` command.\nThe name of the bundle becomes a reference to this particular Gemfile.lock.\n\nInstall external gems that can be later referenced as `@\u003cbundle-name\u003e//:\u003cgem-name\u003e`,\nand the executables from each gem can be accessed as `@\u003cbundle-name//:bin/\u003cgem-binary-name\u003e`\nfor instance, `@bundle//:bin/rubocop`.\n\nYou can install more than one bundle per WORKSPACE, but that's not recommended.\n\n```python\nrb_bundle(\n  name = \"bundle\",\n  gemfile = \":Gemfile\",\n  gemfile_lock = \":Gemfile.lock\",\n  bundler_version = \"2.1.2\",\n  full_index = True,\n)\n\nrb_bundle(\n  name = \"bundle_app_shopping\",\n  gemfile = \"//apps/shopping:Gemfile\",\n  gemfile_lock = \"//apps/shopping:Gemfile.lock\",\n  bundler_version = \"2.1.2\",\n  full_index = True,\n)\n```\n\n### `BUILD.bazel` files\n\nAdd `rb_library`, `rb_binary` or `rb_test` into your `BUILD.bazel` files.\n\n```python\nload(\n    \"@coinbase_rules_ruby//ruby:defs.bzl\",\n    \"rb_binary\",\n    \"rb_library\",\n    \"rb_test\",\n    \"rb_rspec\",\n)\n\nrb_library(\n    name = \"foo\",\n    srcs = glob([\"lib/**/*.rb\"]),\n    includes = [\"lib\"],\n    deps = [\n      \"@bundle//:activesupport\",\n      \"@bundle//:awesome_print\",\n      \"@bundle//:rubocop\",\n    ]\n)\n\nrb_binary(\n    name = \"bar\",\n    srcs = [\"bin/bar\"],\n    deps = [\":foo\"],\n)\n\nrb_test(\n    name = \"foo-test\",\n    srcs = [\"test/foo_test.rb\"],\n    deps = [\":foo\"],\n)\n\nrb_rspec(\n    name = \"foo-spec\",\n    specs = glob([\"spec/**/*.rb\"]),\n    rspec_args = { \"--format\": \"progress\" },\n    deps = [\":foo\"]\n}\n\n```\n\n## Rules\n\nThe following diagram attempts to capture the implementation behind `rb_library` that depends on the result of `bundle install`, and a `rb_binary` that depends on both:\n\n![Ruby Rules](docs/img/rules_ruby.png)\n\n\n### `rb_library`\n\n\u003cpre\u003e\nrb_library(name, deps, srcs, data, compatible_with, deprecation, distribs, features, licenses, restricted_to, tags, testonly, toolchains, visibility)\n\u003c/pre\u003e\n\n\u003ctable class=\"table table-condensed table-bordered table-params\"\u003e\n  \u003ccolgroup\u003e\n    \u003ccol class=\"col-param\" /\u003e\n    \u003ccol class=\"param-description\" /\u003e\n  \u003c/colgroup\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth colspan=\"2\"\u003eAttributes\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ename\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName, required\u003c/code\u003e\n        \u003cp\u003eA unique name for this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003esrcs\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of Labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of \u003ccode\u003e.rb\u003c/code\u003e files.\n        \u003c/p\u003e\n        \u003cp\u003eAt least \u003ccode\u003esrcs\u003c/code\u003e or \u003ccode\u003edeps\u003c/code\u003e must be present\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003edeps\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of targets that are required by the \u003ccode\u003esrcs\u003c/code\u003e Ruby\n          files.\n        \u003c/p\u003e\n        \u003cp\u003eAt least \u003ccode\u003esrcs\u003c/code\u003e or \u003ccode\u003edeps\u003c/code\u003e must be present\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003eincludes\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of paths to be added to \u003ccode\u003e$LOAD_PATH\u003c/code\u003e at runtime.\n          The paths must be relative to the the workspace which this rule belongs to.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003erubyopt\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of options to be passed to the Ruby interpreter at runtime.\n        \u003c/p\u003e\n        \u003cp\u003e\n          NOTE: \u003ccode\u003e-I\u003c/code\u003e option should usually go to \u003ccode\u003eincludes\u003c/code\u003e attribute.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd colspan=\"2\"\u003eAnd other \u003ca href=\"https://docs.bazel.build/versions/master/be/common-definitions.html#common-attributes\"\u003ecommon attributes\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n### `rb_binary`\n\n\u003cpre\u003e\nrb_binary(name, deps, srcs, data, main, compatible_with, deprecation, distribs, features, licenses, restricted_to, tags, testonly, toolchains, visibility, args, output_licenses)\n\u003c/pre\u003e\n\n\u003ctable class=\"table table-condensed table-bordered table-params\"\u003e\n  \u003ccolgroup\u003e\n    \u003ccol class=\"col-param\" /\u003e\n    \u003ccol class=\"param-description\" /\u003e\n  \u003c/colgroup\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth colspan=\"2\"\u003eAttributes\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ename\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName, required\u003c/code\u003e\n        \u003cp\u003eA unique name for this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003esrcs\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of Labels, required\u003c/code\u003e\n        \u003cp\u003e\n          List of \u003ccode\u003e.rb\u003c/code\u003e files.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003edeps\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of targets that are required by the \u003ccode\u003esrcs\u003c/code\u003e Ruby\n          files.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003emain\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eLabel, optional\u003c/code\u003e\n        \u003cp\u003eThe entrypoint file. It must be also in \u003ccode\u003esrcs\u003c/code\u003e.\u003c/p\u003e\n        \u003cp\u003eIf not specified, \u003ccode\u003e\u003cvar\u003e$(NAME)\u003c/var\u003e.rb\u003c/code\u003e where \u003ccode\u003e$(NAME)\u003c/code\u003e is the \u003ccode\u003ename\u003c/code\u003e of this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003eincludes\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of paths to be added to \u003ccode\u003e$LOAD_PATH\u003c/code\u003e at runtime.\n          The paths must be relative to the the workspace which this rule belongs to.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003erubyopt\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of options to be passed to the Ruby interpreter at runtime.\n        \u003c/p\u003e\n        \u003cp\u003e\n          NOTE: \u003ccode\u003e-I\u003c/code\u003e option should usually go to \u003ccode\u003eincludes\u003c/code\u003e attribute.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd colspan=\"2\"\u003eAnd other \u003ca href=\"https://docs.bazel.build/versions/master/be/common-definitions.html#common-attributes\"\u003ecommon attributes\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n### `rb_test`\n\n\u003cpre\u003e\nrb_test(name, deps, srcs, data, main, compatible_with, deprecation, distribs, features, licenses, restricted_to, tags, testonly, toolchains, visibility, args, size, timeout, flaky, local, shard_count)\n\u003c/pre\u003e\n\n\u003ctable class=\"table table-condensed table-bordered table-params\"\u003e\n  \u003ccolgroup\u003e\n    \u003ccol class=\"col-param\" /\u003e\n    \u003ccol class=\"param-description\" /\u003e\n  \u003c/colgroup\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth colspan=\"2\"\u003eAttributes\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ename\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName, required\u003c/code\u003e\n        \u003cp\u003eA unique name for this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003esrcs\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of Labels, required\u003c/code\u003e\n        \u003cp\u003e\n          List of \u003ccode\u003e.rb\u003c/code\u003e files.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003edeps\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of targets that are required by the \u003ccode\u003esrcs\u003c/code\u003e Ruby\n          files.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003emain\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eLabel, optional\u003c/code\u003e\n        \u003cp\u003eThe entrypoint file. It must be also in \u003ccode\u003esrcs\u003c/code\u003e.\u003c/p\u003e\n        \u003cp\u003eIf not specified, \u003ccode\u003e\u003cvar\u003e$(NAME)\u003c/var\u003e.rb\u003c/code\u003e where \u003ccode\u003e$(NAME)\u003c/code\u003e is the \u003ccode\u003ename\u003c/code\u003e of this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003eincludes\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of paths to be added to \u003ccode\u003e$LOAD_PATH\u003c/code\u003e at runtime.\n          The paths must be relative to the the workspace which this rule belongs to.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003erubyopt\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of strings, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of options to be passed to the Ruby interpreter at runtime.\n        \u003c/p\u003e\n        \u003cp\u003e\n          NOTE: \u003ccode\u003e-I\u003c/code\u003e option should usually go to \u003ccode\u003eincludes\u003c/code\u003e attribute.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd colspan=\"2\"\u003eAnd other \u003ca href=\"https://docs.bazel.build/versions/master/be/common-definitions.html#common-attributes\"\u003ecommon attributes\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n### `rb_bundle`\n\nInstalls gems with Bundler, and make them available as a `rb_library`.\n\nExample: `WORKSPACE`:\n\n```python\ngit_repository(\n    name = \"coinbase_rules_ruby\",\n    remote = \"https://github.com/coinbase/rules_ruby.git\",\n    tag = \"v0.1.0\",\n)\n\nload(\n    \"@coinbase_rules_ruby//ruby:deps.bzl\",\n    \"ruby_register_toolchains\",\n    \"rules_ruby_dependencies\",\n)\n\nrules_ruby_dependencies()\n\nruby_register_toolchains()\n\nload(\"@coinbase_rules_ruby//ruby:defs.bzl\", \"rb_bundle\")\n\nrb_bundle(\n    name = \"gems\",\n    gemfile = \"//:Gemfile\",\n    gemfile_lock = \"//:Gemfile.lock\",\n)\n```\n\nExample: `lib/BUILD.bazel`:\n\n```python\nrb_library(\n    name = \"foo\",\n    srcs = [\"foo.rb\"],\n    deps = [\"@gems//:all\"],\n)\n```\n\nOr declare many gems in your `Gemfile`, and only use some of them in each ruby library:\n\n```python\nrb_binary(\n    name = \"rubocop\",\n    srcs = [\":foo\", \".rubocop.yml\"],\n    args = [\"-P\", \"-D\", \"-c\" \".rubocop.yml\"],\n    main = \"@gems//:bin/rubocop\",\n    deps = [\"@gems//:rubocop\"],\n)\n```\n\n\u003cpre\u003e\nrb_bundle(name, gemfile, gemfile_lock, bundler_version = \"2.1.2\")\n\u003c/pre\u003e\n\u003ctable class=\"table table-condensed table-bordered table-params\"\u003e\n  \u003ccolgroup\u003e\n    \u003ccol class=\"col-param\" /\u003e\n    \u003ccol class=\"param-description\" /\u003e\n  \u003c/colgroup\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth colspan=\"2\"\u003eAttributes\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ename\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName, required\u003c/code\u003e\n        \u003cp\u003eA unique name for this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003egemfile\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eLabel, required\u003c/code\u003e\n        \u003cp\u003e\n          The \u003ccode\u003eGemfile\u003c/code\u003e which Bundler runs with.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003egemfile_lock\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eLabel, required\u003c/code\u003e\n          \u003cp\u003eThe \u003ccode\u003eGemfile.lock\u003c/code\u003e which Bundler runs with.\u003c/p\u003e\n          \u003cp\u003eNOTE: This rule never updates the \u003ccode\u003eGemfile.lock\u003c/code\u003e. It is your responsibility to generate/update \u003ccode\u003eGemfile.lock\u003c/code\u003e\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ebundler_version\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eString, optional\u003c/code\u003e\n          \u003cp\u003eThe Version of Bundler to use. Defaults to 2.1.2.\u003c/p\u003e\n          \u003cp\u003eNOTE: This rule never updates the \u003ccode\u003eGemfile.lock\u003c/code\u003e. It is your responsibility to generate/update \u003ccode\u003eGemfile.lock\u003c/code\u003e\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003efull_index\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eBool, optional\u003c/code\u003e\n          \u003cp\u003eSet to True to add the --full-index option to the bundle install. Can improve performance.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n## rb_gem\nUsed to generate a zipped gem containing its srcs, dependencies and a gemspec.\n\n\u003cpre\u003e\nrb_gem(name, gem_name, version, srcs, authors, deps, data, includes)\n\u003c/pre\u003e\n\u003ctable class=\"table table-condensed table-bordered table-params\"\u003e\n  \u003ccolgroup\u003e\n    \u003ccol class=\"col-param\" /\u003e\n    \u003ccol class=\"param-description\" /\u003e\n  \u003c/colgroup\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth colspan=\"2\"\u003eAttributes\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003ename\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName, required\u003c/code\u003e\n        \u003cp\u003eA unique name for this rule.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003egem_name\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eName of the gem, required\u003c/code\u003e\n        \u003cp\u003eThe name of the gem to be generated.\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003eversion\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eLabel, required\u003c/code\u003e\n        \u003cp\u003e\n          The version of the gem. Is used to name the output file,\n          which becomes \u003ccode\u003ename-version.zip\u003c/code\u003e, and also\n          included in the Gemspec.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003eauthors\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of Strings, required\u003c/code\u003e\n        \u003cp\u003e\n          List of human readable names of the gem authors.\n          Required to generate a valid gemspec.\n        \u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003esrcs\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of Labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of \u003ccode\u003e.rb\u003c/code\u003e files.\n        \u003c/p\u003e\n        \u003cp\u003eAt least \u003ccode\u003esrcs\u003c/code\u003e or \u003ccode\u003edeps\u003c/code\u003e must be present\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\u003ccode\u003edeps\u003c/code\u003e\u003c/td\u003e\n      \u003ctd\u003e\n        \u003ccode\u003eList of labels, optional\u003c/code\u003e\n        \u003cp\u003e\n          List of targets that are required by the \u003ccode\u003esrcs\u003c/code\u003e Ruby\n          files.\n        \u003c/p\u003e\n        \u003cp\u003eAt least \u003ccode\u003esrcs\u003c/code\u003e or \u003ccode\u003edeps\u003c/code\u003e must be present\u003c/p\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n## What's coming next\n\n1. Building native extensions in gems with Bazel\n2. Using a specified version of Ruby.\n3. Releasing your gems with Bazel\n\n## Contributing\n\nWe welcome contributions to RulesRuby.\n\nYou may notice that there is more than one Bazel WORKSPACE inside this repo. There is one in `examples/simple_script` for instance, because\nwe use this example to validate and test the rules. So be mindful whether your current directory contains `WORKSPACE` file or not.\n\n### Setup\n\n#### OSX Setup Script\n\nYou will need Homebrew installed prior to running the script.\n\nAfter that, cd into the top level folder and run the setup script in your Terminal:\n\n```bash\n❯ bin/setup-darwin\n```\n##### Issues During Setup\n\n**Please report any errors as Issues on Github.**\n\n### Developing Rules\n\nBesides making yourself familiar with the existing code, and [Bazel documentation on writing rules](https://docs.bazel.build/versions/master/skylark/concepts.html), you might want to follow this order:\n\n  1. Setup dev tools as described in the [setup](#Setup) section.\n  3. hack, hack, hack...\n  4. Make sure all tests pass — you can run individual Bazel test commands from the inside.\n\n   * `bazel test //...`\n   * `cd examples/simple_script \u0026\u0026 bazel test //...`\n\n  4. Open a pull request in Github, and please be as verbose as possible in your description.\n\nIn general, it's always a good idea to ask questions first — you can do so by creating an issue.\n\n### Running Tests\n\nAfter running setup, and since this is a bazel repo you can use Bazel commands:\n\n```bazel\nbazel build //...:all\nbazel query //...:all\nbazel test //...:all\n```\n\nBut to run tests inside each sub-WORKSPACE, you will need to repeat that in each sub-folder.\n\n### Linter\n\nWe are using RuboCop for ruby and Buildifier for Bazel. Both can be run using bazel:\n\n```bash\nbazel run //:buildifier\n```\n\n## Copyright\n\n© 2018-2019 Yuki Yugui Sonoda \u0026 BazelRuby Authors\n\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in compliance with the License. You may obtain a copy of the License at\n\n\u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e\n\nUnless required by applicable law or agreed to in writing, software distributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoinbase%2Frules_ruby","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcoinbase%2Frules_ruby","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoinbase%2Frules_ruby/lists"}