Fix #148, add documentation regarding PROMPT_COMMAND. Bump to v21.0.1

pull/139/head
William Ting 12 years ago
parent 5745c34c23
commit 1a032a97b4

@ -34,7 +34,7 @@ import re
import shutil import shutil
from tempfile import NamedTemporaryFile from tempfile import NamedTemporaryFile
VERSION = 'release-v21' VERSION = 'release-v21.0.1'
MAX_KEYWEIGHT = 1000 MAX_KEYWEIGHT = 1000
MAX_STORED_PATHS = 1000 MAX_STORED_PATHS = 1000
COMPLETION_SEPARATOR = '__' COMPLETION_SEPARATOR = '__'

@ -20,25 +20,35 @@ Options must be passed to 'autojump' and not the 'j' wrapper function.
- Enable ZSH Tab Completion - Enable ZSH Tab Completion
ZSH tab completion requires the `compinit` module to be loaded. Please add the following line to your ~/.zshrc: ZSH tab completion requires the `compinit` module to be loaded. Please add
the following line to your ~/.zshrc:
autoload -U compinit; compinit autoload -U compinit; compinit
- Always Ignore Case - Always Ignore Case
Default behavior is to prioritize exact matches over all else. For example, `j foo` will prefer /foobar over /FooBar even if the latter has a higher weight. To change this behavior and ignore case, add the following environmental variable in your ~/.bashrc: Default behavior is to prioritize exact matches over all else. For example,
`j foo` will prefer /foobar over /FooBar even if the latter has a higher
weight. To change this behavior and ignore case, add the following
environmental variable in your ~/.bashrc:
export AUTOJUMP_IGNORE_CASE=1 export AUTOJUMP_IGNORE_CASE=1
- Prevent Database Entries' Decay - Prevent Database Entries' Decay
Default behavior is to decay unused database entries slowly over time. Eventually when database limits are hit and maintenance is run, autojump will purge older less used entries. To prevent decay, add the following variable in your ~/.bashrc: Default behavior is to decay unused database entries slowly over time.
Eventually when database limits are hit and maintenance is run, autojump
will purge older less used entries. To prevent decay, add the following
variable in your ~/.bashrc:
export AUTOJUMP_KEEP_ALL_ENTRIES=1 export AUTOJUMP_KEEP_ALL_ENTRIES=1
- Prefer Symbolic Links - Prefer Symbolic Links
Default behavior is to evaluate symbolic links into full paths as to reduce duplicate entries in the database. However, some users prefer a shorter working directory path in their shell prompt. To switch behavior to prefer symbolic links, add the following environmental variable in your ~/.bashrc: Default behavior is to evaluate symbolic links into full paths as to reduce
duplicate entries in the database. However, some users prefer a shorter
working directory path in their shell prompt. To switch behavior to prefer
symbolic links, add the following environmental variable in your ~/.bashrc:
export AUTOJUMP_KEEP_SYMLINKS=1 export AUTOJUMP_KEEP_SYMLINKS=1
@ -48,18 +58,24 @@ Options must be passed to 'autojump' and not the 'j' wrapper function.
Let's assume the following database: Let's assume the following database:
30 /home/user/mail/inbox 30 /home/user/mail/inbox 10 /home/user/work/inbox
10 /home/user/work/inbox
`j in` would jump into /home/user/mail/inbox as the higher weighted entry. However you can pass multiple arguments to autojump to prefer a different entry. In the above example, `j w in` would then jump you into /home/user/work/inbox. `j in` would jump into /home/user/mail/inbox as the higher weighted entry.
However you can pass multiple arguments to autojump to prefer a different
entry. In the above example, `j w in` would then jump you into
/home/user/work/inbox.
- ZSH Tab Completion - ZSH Tab Completion
Tab completion requires two tabs before autojump will display the completion menu. However if `setopt nolistambiguous` is enabled, then only one tab is required. Tab completion requires two tabs before autojump will display the completion
menu. However if `setopt nolistambiguous` is enabled, then only one tab is
required.
- Change Directory Weight - Change Directory Weight
To manually change a directory's key weight, you can edit the file _$XDG_DATA_HOME/autojump/autojump.txt_. Each entry has two columns. The first is the key weight and the second is the path: To manually change a directory's key weight, you can edit the file
_$XDG_DATA_HOME/autojump/autojump.txt_. Each entry has two columns. The
first is the key weight and the second is the path:
29.3383211216 /home/user/downloads 29.3383211216 /home/user/downloads
@ -67,7 +83,19 @@ Options must be passed to 'autojump' and not the 'j' wrapper function.
## KNOWN ISSUES ## KNOWN ISSUES
- The jump function `j` does not support directories that begin with `-`. If you want to jump a directory called `--music`, try using `j music` instead of `j --music`. - For bash users, autojump keeps track of directories as a pre-command hook by
modifying $PROMPT_COMMAND. If you overwrite $PROMPT_COMMAND in ~/.bashrc you
can cause problems. Don't do this:
export PROMPT_COMMAND="history -a"
Do this:
export PROMPT_COMMAND="${PROMPT_COMMAND}; history -a"
- The jump function `j` does not support directories that begin with `-`. If you
want to jump a directory called `--music`, try using `j music` instead of `j
--music`.
- jumpapplet (bug #59) - jumpapplet (bug #59)
@ -93,12 +121,17 @@ _https://groups.google.com/forum/?fromgroups#!forum/autojump_
## THANKS ## THANKS
Special thanks goes out to: Pierre Gueth, Simon Marache-Francisco, Daniel Jackoway, and many others. Special thanks goes out to: Pierre Gueth, Simon Marache-Francisco, Daniel
Jackoway, and many others.
## AUTHORS ## AUTHORS
autojump was originally written by Joël Schaerer, and currently maintained by William Ting. autojump was originally written by Joël Schaerer, and currently maintained by
William Ting.
## COPYRIGHT ## COPYRIGHT
Copyright © 2012 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Copyright © 2012 Free Software Foundation, Inc. License GPLv3+: GNU GPL version
3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are
free to change and redistribute it. There is NO WARRANTY, to the extent
permitted by law.

Loading…
Cancel
Save