Instructions for installing command completion in Linux bash
Dylan Powers committed
Apr 21, 2015 at 11:50 UTC
71e8919101dcba5f3f70a467e377e2ff59eaaa5e
2 files changed
+22
-1
README.md
+1
-1
@@ -32,7 +32,7 @@ dependencies as well.
32
We strongly recommend you use the [latest version of OSX FUSE](http://osxfuse.github.io/).
33
(See https://github.com/ipfs/go-ipfs/issues/177)
34
* For more details on setting up FUSE (so that you can mount the filesystem), see the docs folder
35
-* Shell command completion is available by running `source misc/completion/ipfs-completion.bash`.
35
+* Shell command completion is available in `misc/completion/ipfs-completion.bash`. Read [docs/command-completion.md](docs/command-completion.md) to learn how to install it.
36
37
38
## Usage
docs/command-completion.md
new
+21
@@ -0,0 +1,21 @@
1
+Command Completion
2
+==================
3
+
4
+Shell command completion is provided by the script at
5
+`/misc/completion/ipfs-completion.bash`.
6
+
7
+The simplest way to see it working is to run
8
+`source misc/completion/ipfs-completion.bash` straight from your shell. This
9
+is only temporary and to fully enable it, you'll have to follow one of the steps
10
+below.
11
+
12
+Linux
13
+-----
14
+### Bash
15
+
16
+For bash, completion can be enabled in a couple of ways. One is to add the line
17
+`source $GOPATH/src/github.com/ipfs/go-ipfs/misc/completion/ipfs-completion.bash`
18
+into your `~/.bash_completion`. It will automatically be loaded the next time
19
+bash is loaded.
20
+To enable ipfs command completion globally on your system you may also
21
+copy the completion script to `/etc/bash_completion.d/`.