Issue resolved. Thanks to everyone for help! On Fri, Jan 7, 2011 at 8:36 AM, ZyX <[email protected]> wrote: > Reply to message «NERDTree on startup», > sent 14:31:04 07 January 2011, Friday > by beo wulf: > > ``normal "<C-w>l"'' is a wrong syntax, you should use > ``execute "normal \<C-w>l"''. With this everything works. In your original > version normal command stops after «"<» because «"<» is «select register `<' > for > the next command» and register `<' does not exist. There are also some other > notes: 1) <C-w>l in normal mode can be translated into «wincmd l»; 2) in any > case, use «normal!» instead of just «normal» where possible. > > Original message: >> Is it possible to have NERDtree loaded on startup, but to have the >> cursor not in the NERDTree buffer? >> >> I have tried: >> >> function! LoadNERDTree() >> >> :NERDTree >> >> normal "<c-w>l" >> endf >> >> :au VimEnter * :call LoadNERDTree() >> >> But the problem is that I end up starting in the NERDTree buffer >> rather than the buffer of the file I want to edit. >> >> Thanks! >
-- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php
