Updates git functions, vimrc, etc.

This commit is contained in:
William Carroll 2016-12-19 20:53:45 -05:00
parent 17f7e0c453
commit 9c8ffdb504
8 changed files with 62 additions and 18 deletions

View file

@ -60,7 +60,7 @@ function wgjira {
# wgcheckout combined with a fuzzy search
function wgfcheckout {
branchname=$(trim $(git branch | fzf))
branchname=$(trim $(git branch | fzf-tmux))
[ ! -z "$branchname" ] && wgcheckout "$branchname" || return
}

View file

@ -1,12 +1,12 @@
# fuzzily-find-file
function wgff {
echo $(find . -type f | fzf)
echo $(find . -type f | fzf-tmux)
}
# fuzzily-find-branch
function wgfb {
echo $(git branch -a | fzf)
echo $(git branch -a | fzf-tmux)
}
@ -28,13 +28,13 @@ function wspcheck {
# fuzzily search through dirs stack
function wfd {
dir=$(dirname $(fzf)) && pushd "$dir" >/dev/null
dir=$(dirname $(fzf-tmux)) && pushd "$dir" >/dev/null
}
# pushd into a directory on your dirs stack
function wpushd {
dir="$(dirs | tr ' ' '\n' | fzf)" && pushd "$dir"
dir="$(dirs | tr ' ' '\n' | fzf-tmux)" && pushd "$dir"
}

View file

@ -13,10 +13,10 @@ function vfzopen() {
if [ ! -z "$exclude_dirs" ]; then
filename=$(find . -type f -name "$filetype" | \
xargs grep -l "$search_query" | fzf)
xargs grep -l "$search_query" | fzf-tmux)
else
filename=$(find . -type f -name "$filetype" -not -path "./${exclude_dir}/*" \
| xargs grep -l "$search_query" | fzf)
| xargs grep -l "$search_query" | fzf-tmux)
fi