$vim ~/xxx/yyy/ddd/eee/fff/file1.txt
While editing, we realise we want to open file2.txt which is in the same directory as file1.txt
I find it very annoying have to type :sp ~/xxx/yyy/.....
The other option is to close vim, navigate to the said directory and open the files, which too I find annoying.
There is solace - two solutions
1) Use the command :cd %:h in vim 6 to navigate vim to the particular directory the file that you are editing is placed in. Now you just have to do a :e file2.txt to open the other files.
2) I don't like that solution either because, I change my vim's path. What if I want to open a file from the original place I started vim. Add the following to your vimrc:
if has("unix")
map ,e :e
else
map ,e :e
endif
Now in command mode, press ",e", presto, the directory path gets filled in! You can continue to use :e for the original directory you started vim in.