3

Netrw able to execute file with xdg-open by pressing x, how about NERDTree ?

[Response to downvote]

If xdg-open can so easy/direct to work (which is the reason of downvote), then what's the point for this plugin (https://github.com/aufgang001/vim-nerdtree_plugin_open) exist ? Of course i do a quick try but it didn't work too.

3
  • Try :help nerdtree.
    – romainl
    Nov 11, 2016 at 22:47
  • 1
    Thanks for those downvote because i'm not even can make help manual work for NERDTree. Both :helptags ~/.vim/doc and help ~/.vim/bundle/nerdtree/doc/ doesn't work. Which keyword should i use to grep the 1253 lines' help file ? external and xdg doesn't work. and simply o is open file in vim, not xdg-open.
    – 林果皞
    Nov 11, 2016 at 23:02
  • 1
    You are not supposed to "grep" the help file; you are supposed to "read" it. Once you have read it and it doesn't mention xdg-open anywhere, what conclusion can you make about NERDTree's ability to use xdg-open? Anyway, this place is not a support board for random plugins. Use their issue tracker.
    – romainl
    Nov 12, 2016 at 0:23

2 Answers 2

6

For those curious, if NerdTree can xdg-open: Yes it can.

  • Put the cursor on the desired file.

  • Press m for the context menu.

  • Press o to open in the system editor.

  • Enjoy.

3

I figure out the reason why this plugin doesn't work:

git clone https://github.com/aufgang001/vim-nerdtree_plugin_open.git ~/.vim/vim-nerdtree_plugin_open.git

The instruction is wrong, it should put inside ~/.vim/bundle (at least in my case):

git clone https://github.com/aufgang001/vim-nerdtree_plugin_open.git  ~/.vim/bundle/vim-nerdtree_plugin_open.git

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.