commit 9f08dd4b2690cccc3868f6462facfe3fb3bda760
parent 54ec2aee7951013c5ecc03031a59c089bb676b71
Author: Lucas Burns <burnsac@me.com>
Date: Sun, 9 May 2021 21:38:57 -0500
fixed zsh completion
Diffstat:
2 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
@@ -2,9 +2,9 @@
This is a fork of [`dotbare`](https://github.com/kazhala/dotbare). The scripts are modified to work with a regular `git` directory.
-### Installation:
+## Installation:
-#### Manual - use as a script
+### Manual - use as a script
```sh
git clone https://github.com/lmburns/fzfgit.git
@@ -12,14 +12,14 @@ cd fzfgit
make install
```
-#### zsh
+### zsh
-##### zinit
+#### zinit
```sh
zinit light lmburns/fzfgit
```
-##### oh-my-zsh
+#### oh-my-zsh
```sh
git clone https://github.com/lmburns/fzfgit.git ${ZDOTDIR:-$HOME}/.oh-my-zsh/custom/plugins/fzfgit
@@ -27,12 +27,12 @@ git clone https://github.com/lmburns/fzfgit.git ${ZDOTDIR:-$HOME}/.oh-my-zsh/cus
plugins=( fzfgit )
```
-##### Antigen
+#### Antigen
```sh
antigen bundle lmburns/fzfgit
```
-##### Manual - use as a `zsh` plugin
+#### Manual - use as a `zsh` plugin
```sh
git clone https://github.com/lmburns/fzfgit.git ${ZDOTDIR:-$HOME}/.fzfgit
@@ -214,5 +214,5 @@ export FZFGIT_DIFF_PAGER="delta --diff-so-fancy --line-numbers"
Top level directory where the current directory you are in can be backed up to. I am working on allowing specification of a path to a directory that you're currently not in.
```sh
-export FZFGIT_BACKUP="$XDG_DATA_HOME/gitbackup"
+export FZFGIT_BACKUP="{$XDG_DATA_HOME}/gitbackup"
```
diff --git a/fzfgit.plugin.zsh b/fzfgit.plugin.zsh
@@ -172,6 +172,8 @@ _widget_git_transform_fzfgit() {
if ($2 ~ /(log|add|reset|checkout|status|stash|grep|untrack|stat)/) {
if ($2 == "status"){
$2="stat"
+ } else if ($2 == "grep"){
+ $2="zgrep"
}
$2="f"$2
}