I'm dealing with java projects which often result in deeply nested folders (/path/to/project/com/java/lang/whatever, etc) and sometimes want to be able to jump, say, 4 directory levels upwards. Typing cd ../../../.. is a pain, and I don't want to symlink. Is there some flag to cd that lets you go up multiple directory levels (in my head, it would be something like cd -u 4)? Unfortunately I can't find any man page for cd specifically, instead just getting the useless "builtins" page.
|
Or... try this: (yay Google)
See Hack #2 |
|||||||
|
|
Turns out the correct answer is 'cd +n', where n is the number of levels you want to go up. Too bad this isn't documented anywhere! |
|||||
|
|
|
Not exactly what you're asking for but you should look into If you're going back and forth from a couple fixed areas, the usual thing is to have aliases.
|
|||
|
|
|
Do you know about autojump? It's a third party hack, but can be useful in your scenario. |
|||
|
|