Autojump: Maybe I am a retard, but autojump doesn't seem to work on Natty Narwhal

Created on 25 Jul 2011  ·  23Comments  ·  Source: wting/autojump

Hello,

I installed autojump in Ubuntu 11.04 from synaptic and I can't get it to work. I added source /etc/profile in my bashrc,
closed and opened my terminal again, and whenever I try to use jumpstat it says command not found.
I tried to train jumpstat by navigating a bit in my filesystem, but when I try j derp to go to a directory, it also says j: command not found.

Am I missing something?

bug

Most helpful comment

Same here on 13.04.

Update: For anyone having this issue just do what it says in the readme.md.
cat /usr/share/doc/autojump/README.Debian

Update2: j works now with the above instructions but jo and jc and jco do not, 'command not found'. I think it is because Ubuntu's repo is at v20 (autojump --version) and the latest tag I see is at v21.6.9

All 23 comments

I can confirm this is not normal at all :)

Can you try sourcing /etc/profile.d/autojump.bash (assuming you're using bash) directly in your bashrc? Then j and jumpstat should be defined (they're bash aliases), and the PROMPT_COMMAND environment variable should contain autojump related stuff.

Hello,

I did what you explained and now when I open a terminal I get:

bash: /etc/profile.d/autojump.bash: No such file or directory
cbrunos@foxdie: ~$

Any other ideas?

On Tue, Jul 26, 2011 at 10:08 AM, joelthelion <
[email protected]>wrote:

I can confirm this is not normal at all :)

Can you try sourcing /etc/profile.d/autojump.bash (assuming you're using
bash) directly in your bashrc? Then j and jumpstat should be defined
(they're bash aliases), and the PROMPT_COMMAND environment variable should
contain autojump related stuff.

Reply to this email directly or view it on GitHub:
https://github.com/joelthelion/autojump/issues/65#issuecomment-1652441

Rodrigues Bruno

http://cbrunos.wordpress.com

Ok, so I downloaded the latest autojump version (v15) and copy pasted autojump.bash to /etc/profile.d and now it works great. I think it's a problem with the package that is on Ubuntu repos?

I'd be interested if another ubuntu user can comment on this?

@cbrunos: would you mind pasting the output of

dpkg -L autojump

Sure, here it is:

cbrunos@bamboo:~$ dpkg -L autojump
/.
/usr
/usr/bin
/usr/bin/autojump
/usr/share
/usr/share/man
/usr/share/man/man1
/usr/share/man/man1/autojump.1.gz
/usr/share/autojump
/usr/share/autojump/autojump.bash
/usr/share/autojump/autojump.zsh
/usr/share/autojump/autojump.sh
/usr/share/zsh
/usr/share/zsh/functions
/usr/share/zsh/functions/Completion
/usr/share/zsh/functions/Completion/Unix
/usr/share/zsh/functions/Completion/Unix/_j
/usr/share/doc
/usr/share/doc/autojump
/usr/share/doc/autojump/README.Debian
/usr/share/doc/autojump/copyright
/usr/share/doc/autojump/README.rst.gz
/usr/share/doc/autojump/changelog.Debian.gz
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/autojump

I've asked the debian maintainer about this problem, and you need to source /usr/share/autojump.bash (instead of /etc/profile.d/autojump.bash) in your bashrc, as described in the documentation of the package.

I installed autojump in oneiric, and "locate autojump.bash" gives me /usr/share/autojump/autojump.bash, so for everyone having trouble this should be the file to source.

Seems strange that the Ubuntu doesn't source autojump.bash by default. I can confirm that this is still the case under 12.04.

apt-file is useful for diagnosing stuff like this, see http://askubuntu.com/questions/173821/

Using 12.04, same happened for me.

This is most likely due to a Debian policy where we're not allowed to modify user profile files upon installation. Since Ubuntu is downstream, it's unlikely they've changed behavior back to what should be expected unless they repatched over Debian's patch.

Same problem here on 12.10 - Since you install autojump by hand, it should autoconfigure it to work with bash or at least ask you for it or display some informations.

Same problem with Ubuntu 13.04
Autojump doesn't work and j is not found.

Any alternate place to install autojump ?

@yugal: I'll need to look into it, but don't have time right now.

In the mean time you should manually install autojump.

Same here on 13.04.

Update: For anyone having this issue just do what it says in the readme.md.
cat /usr/share/doc/autojump/README.Debian

Update2: j works now with the above instructions but jo and jc and jco do not, 'command not found'. I think it is because Ubuntu's repo is at v20 (autojump --version) and the latest tag I see is at v21.6.9

There is file that needs to be sourced for it to work. I don't remember which ( Please google ).
This is due to security policies that it can-not be done automatically. ( If I am not wrong )

If you are using oh-my-zsh like myself, then you can add autojump plugin in .zshrc which does the needful for autojump to work.

I know its a bummer - may be someone comes up with a solution soon.
( I am not one of the developer of autojump - so my info might not be most appropriate )

Refer this : https://github.com/robbyrussell/oh-my-zsh/blob/master/plugins/autojump/autojump.plugin.zsh

You should be fine !

@yugal Thanks for your reply. I got it working by adding the below code to ~/.bash_profile and then running source ~/.bash_profile.

# Manually source autojump - https://github.com/joelthelion/autojump
. /usr/share/autojump/autojump.sh

:)

Thanks. Same problem solved in Ubuntu 12.04.

thanks!

Thanks.

Thanks. Same problem solved in Ubuntu Debian 8.

  1. adding . /usr/share/autojump/autojump.sh ( remember to give whitespace after . :) ) , as told in /usr/share/doc/autojump/README.Debian. ( if you dont find in /usr/share/ in your system. you can download the .deb file and read the README.Debian.
  2. source ~/.bashrc or ~/.bash_profile
  3. Solved :).

thanks everyone :)

//before, i thought some thing wrong in my instalation, but for Debian we have to do it manually.

Yeah, I wish we could do it automatically for users but that runs afoul of Debian's guidelines. :crying_cat_face:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rsparkyc picture rsparkyc  ·  11Comments

davux picture davux  ·  9Comments

turingking picture turingking  ·  12Comments

qazip picture qazip  ·  3Comments

juanrgon picture juanrgon  ·  4Comments