Skip to content

Commit

Permalink
Merge pull request clvv#9 from benohara/master
Browse files Browse the repository at this point in the history
Make location of viminfo configurable
  • Loading branch information
Wei Dai committed Jul 1, 2012
2 parents 77b00ae + 4351254 commit eb223be
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 1 deletion.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,9 @@ $_FASD_FUZZY
Level of "fuzziness" when doing fuzzy matching. More precisely, the number of
characters that can be skipped to generate a match. Set to empty or 0 to
disable fuzzy matching. Default value is 2.
$_FASD_VIMINFO
Location of .viminfo file if not located in "$HOME/.viminfo"
```

# Debugging
Expand Down
3 changes: 2 additions & 1 deletion fasd
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ fasd() {
[ -z "$_FASD_MAX" ] && _FASD_MAX=2000
[ -z "$_FASD_BACKENDS" ] && _FASD_BACKENDS=native
[ -z "$_FASD_FUZZY" ] && _FASD_FUZZY=2
[ -z "$_FASD_VIMINFO" ] && _FASD_VIMINFO="$HOME/.viminfo"

if [ -z "$_FASD_AWK" ]; then
# awk preferences
Expand Down Expand Up @@ -470,7 +471,7 @@ $(fasd --backend $each)"
case $2 in
native) cat "$_FASD_DATA";;
viminfo)
< "$HOME/.viminfo" sed -n '/^>/{s@~@'"$HOME"'@
< "$_FASD_VIMINFO" sed -n '/^>/{s@~@'"$HOME"'@
s/^..//
p
}' | $_FASD_AWK -v t="$(date +%s)" '{
Expand Down
3 changes: 3 additions & 0 deletions fasd.1
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,9 @@ $_FASD_FUZZY
Level\ of\ "fuzziness"\ when\ doing\ fuzzy\ matching.\ More\ precisely,\ the\ number\ of
characters\ that\ can\ be\ skipped\ to\ generate\ a\ match.\ Set\ to\ empty\ or\ 0\ to
disable\ fuzzy\ matching.\ Default\ value\ is\ 2.

$_FASD_VIMINFO
Location\ of\ .viminfo\ file\ if\ not\ located\ in\ "$HOME/.viminfo"
\f[]
.fi
.SH DEBUGGING
Expand Down
3 changes: 3 additions & 0 deletions fasd.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ they are present. Below are some variables you can set:
characters that can be skipped to generate a match. Set to empty or 0 to
disable fuzzy matching. Default value is 2.

$_FASD_VIMINFO
Location of .viminfo file if not located in "$HOME/.viminfo"

# DEBUGGING

Fasd is hosted on GitHub: https://github.com/clvv/fasd
Expand Down

0 comments on commit eb223be

Please sign in to comment.