1
#Copyright Joel Schaerer 2008, 2009
2
#This file is part of autojump
4
#autojump is free software: you can redistribute it and/or modify
5
#it under the terms of the GNU General Public License as published by
6
#the Free Software Foundation, either version 3 of the License, or
7
#(at your option) any later version.
9
#autojump is distributed in the hope that it will be useful,
10
#but WITHOUT ANY WARRANTY; without even the implied warranty of
11
#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
#GNU General Public License for more details.
14
#You should have received a copy of the GNU General Public License
15
#along with autojump. If not, see <http://www.gnu.org/licenses/>.
17
function autojump_preexec() {
18
{ (autojump -a "$(pwd -P)"&)>/dev/null 2>>|${HOME}/.autojump_errors ; } 2>/dev/null
21
typeset -ga preexec_functions
22
preexec_functions+=autojump_preexec
24
alias jumpstat="autojump --stat"
26
function j { local new_path="$(autojump $@)";if [ -n "$new_path" ]; then echo -e "\\033[31m${new_path}\\033[0m"; cd "$new_path";fi }