NERDTreeFocus CWD

658 Views Asked by At

I'm trying to use :NERDTreeFocus map <C-n> :NERDTreeFocus<CR>.

I used to launch gvim from ~ then move in my project folder with NERDTree, then I changed the cwd to the project folder path with cd NERDTree shortcut. But if I move in a file then I press <C-n> (:NERDTreeFocus), the pwd will be again ~.

Please help me to fix this mistake.

1

There are 1 best solutions below

0
On

It's about autochdir. See :h 'autochdir'. You can try

set noautochdir

Hope it helps.