How to create a directory using nerdtree
I have been using NERDTree for a while. Every time I need to create a new directory I need to go to terminal. Is there a quick and easy way to create a directory using NERDTree.
I read the doc but could not find anything.
Solution 1:
When in the NERDTree window, press 'm'; you should see a menu at the bottom. Type in 'a' for add childnode. Now input the directory you want to create, making sure to add a '/' at the end, otherwise the script would create a file.
AFAIK NERDTree cannot create parent directories like 'mkdir -p' does.
Solution 2:
Pressing m
would open a menu below and you can select from a list of actions.
NERDTree Menu. Use j/k/enter and the shortcuts indicated
==========================================================
> (a)dd a childnode
(m)ove the current node
(d)elete the current node
(r)eveal in Finder the current node
(o)pen the current node with system editor
(q)uicklook the current node
(c)opy the current node
Add a childnode
==========================================================
Enter the dir/file name to be created. Dirs end with a '/'
/Library/WebServer/Documents/new-teacher-center/app/Model/
Pressing a
would let you add a childnode. A childnode can be a file or folder depending if you add a forward slash ( / ) or not.
If you don’t add a forward slash like below, it would create a file.
Add a childnode
==========================================================
Enter the dir/file name to be created. Dirs end with a '/'
/Library/WebServer/Documents/new-project/app/Model/file
If you add a forward slash like below, it would create a folder.
Add a childnode
==========================================================
Enter the dir/file name to be created. Dirs end with a '/'
/Library/WebServer/Documents/new-project/app/Model/folder/