简体   繁体   中英

NERDTree (Vim): How to open a file with path in NERDTree quickly

I'm newbie in vim (NERDTree). My question: How to open a file with a path by command (like: vim /etc/hosts) And open this file in new tab

Thanks for help.

You can just type in:

:tabnew /path/to/file

If you want to use NERDTree, you can open NERDTree (type :NERDTree ), navigate to your file, and then press t with cursor on the file name. This will open specific file in new tab.

Also, while in NERDTree , you can hit ? . That will show you it's internal help with list of available commands. Hit ? again to exit help and enjoy :)

See also :help NERDTree , if you want more complete documentation.

:tabnew some / path / to / some / file

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM