The title sums it up, really. I'd like to know how to set the current root of the tree when browsing files using netrw in vim.
Any ideas?
You can also use "gn" mapping to change the current directory to the folder under your cursor.
CHANGING TREE TOP netrw-ntree :Ntree netrw-gn {{{2
One may specify a new tree top for tree listings using
:Ntree [dirname]
Without a "dirname", the current line is used (and any leading depth information is elided). With a "dirname", the specified directory name is used.
The "gn" map will take the word below the cursor and use that for changing the top of the tree listing.
Per the documentation for netrw, use the ex command
:Ntree [dirname]
Assuming you have netrw installed, one can obtain more information on this using help
:help Ntree
Often times, I will just change the current work directory using the ex command
:cd [dirname]
Next, I start the explorer (ex command again)
:Exp
***Addendum***********
To update your version of netrw, I would just follow the directions that the author, Charles Campbell, posted on www.vim.org.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With