aboutsummaryrefslogtreecommitdiffhomepage
path: root/site/versions/master/docs
diff options
context:
space:
mode:
authorGravatar Kristina Chodorow <kchodorow@google.com>2017-02-02 16:46:56 +0000
committerGravatar Yun Peng <pcloudy@google.com>2017-02-02 17:00:50 +0000
commit0f00ccbadb5e35b50d3ff9e33abf4b816971ed1e (patch)
treeb6daba042bb1b25892418b6f9c510d48fa77fbd9 /site/versions/master/docs
parent72879217ecaba55dbe1c392c1565592288415605 (diff)
Update docs on bash completion
Fixes #1539. -- PiperOrigin-RevId: 146367911 MOS_MIGRATED_REVID=146367911
Diffstat (limited to 'site/versions/master/docs')
-rw-r--r--site/versions/master/docs/install.md21
1 files changed, 15 insertions, 6 deletions
diff --git a/site/versions/master/docs/install.md b/site/versions/master/docs/install.md
index 957d581219..fb1f562d03 100644
--- a/site/versions/master/docs/install.md
+++ b/site/versions/master/docs/install.md
@@ -325,14 +325,23 @@ If you wish to use JDK 7, follow the same steps as for JDK 8 but with the _jdk7_
## <a name="bash"></a>Getting bash completion
-Bazel comes with a bash completion script. To install it:
+Bazel comes with a bash completion script, which the installer copies into the
+`bin` directory. If you ran the installer with `--user`, this will be
+`$HOME/.bazel/bin`. If you ran the installer as root, this will be
+`/usr/local/bazel/bin`.
+
+Copy the `bazel-complete.bash` script to your completion folder
+(`/etc/bash_completion.d` directory under Ubuntu). If you don't have a
+completion folder, you can copy it wherever suits you and insert
+`source /path/to/bazel-complete.bash` in your `~/.bashrc` file (under OS X, put
+it in your `~/.bash_profile` file).
+
+If you built Bazel from source, the bash completion target is in the `//scripts`
+package:
1. Build it with Bazel: `bazel build //scripts:bazel-complete.bash`.
-2. Copy the script `bazel-bin/scripts/bazel-complete.bash` to your
- completion folder (`/etc/bash_completion.d` directory under Ubuntu).
- If you don't have a completion folder, you can copy it wherever suits
- you and simply insert `source /path/to/bazel-complete.bash` in your
- `~/.bashrc` file (under OS X, put it in your `~/.bash_profile` file).
+2. Copy the script `bazel-bin/scripts/bazel-complete.bash` to one of the
+ locations described above.
## <a name="zsh"></a>Getting zsh completion