Merge pull request #323 from axlan/update-fish-doc

Added instructions for using with fish_config
master
Martin Gondermann 9 years ago committed by GitHub
commit 50a3159995
  1. 23
      README.md
  2. 3
      gitprompt.fish

@ -117,6 +117,29 @@ Add to the `~/.bashrc`:
source ~/.bash-git-prompt/gitprompt.sh
```
### install for the fish shell
- If you cloned the repo to a directory other then ~/.bash-git-prompt , set __GIT_PROMPT_DIR in ~/.config/fish/config.fish
to that path
- To install as an option in the fish_config GUI
```sh
sudo install -m 666 gitprompt.fish /usr/share/fish/tools/web_config/sample_prompts/
fish_config
```
to install the bash-git-prompt as a choice under the prompt tab of the web config. Selecting this will copy it to
~/.config/fish/functions/fish_prompt.fish
- You can also do
```sh
mkdir -p ~/.config/fish/functions/
cp gitprompt.fish ~/.config/fish/functions/fish_prompt.fish
```
to overwrite the current prompt with the bash-git-prompt directly
### All configs for .bashrc
```sh

@ -1,3 +1,6 @@
# name: bash-git-prompt
# author: Mariusz Smykuła <mariuszs@gmail.com>
if not set -q __GIT_PROMPT_DIR
set __GIT_PROMPT_DIR ~/.gitprompt
end

Loading…
Cancel
Save