Skip to content

Commit

Permalink
Merge tag '0.0.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
bttk committed Dec 2, 2018
2 parents 0c3c3ec + 2e7d2a5 commit 3b99e84
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,37 +8,37 @@ This is not an officially supported Google product.

## Setup

1. In the `WORKSPACE` file of your Bazel project add the following:
1. In the WORKSPACE file of your Bazel project add the following:

```python
git_repository(
name = "com_github_google_rules_install",
remote = "https://github.com/google/bazel_rules_install.git",
commit = "{COMMIT_ID}",
remote = "https://github.com/bazelbuild/rules_install.git",
tag = '0.0.1',
)

load("@com_github_google_rules_install//:deps.bzl", "install_rules_dependencies")

install_rules_dependencies()
```

1. In the `BUILD` file of the package where you want to add an installer add the following:
1. In the BUILD file of the package where you want to add an installer add the following:

````python
# In file src/path/to/pkg/BUILD:

load("@com_github_google_rules_install//installer:def.bzl", "installer")
load("@com_github_google_rules_install//:defs.bzl", "installer")

installer(
name = "install_foo",
data = [":foo"],
)
````

1. Run the installer using `bazel run -c opt`. This example installs `foo` in `~/bin`:
1. Run the installer using `bazel run`. This example installs `foo` in `~/bin`:

```shell
bazel run -c opt //src/path/to/pkg:install_foo ~/bin
bazel run //src/path/to/pkg:install_foo -c opt ~/bin
```

## See also
Expand Down

0 comments on commit 3b99e84

Please sign in to comment.