Automatic file directory structure generation tool-filemap.js

  es6, javascript, node.js

Project address:
development environmentnodeVersion 5.4.1


brief introduction

As a frequent blogger, you often need to introduce the file directory structure when introducing your own projects. In the past, either manual codeword input line by line or simple and crude screenshots could not easily and quickly construct a file directory structure diagram. Later, when learning the algorithm, I found that the file directory structure was similar toTreeThe concept is very similar, so it sprouted to make an automated file directory structure generation tool.

How to Use&& Examples

git clone
 cd ./filemap && cd example
 node filemap.js

(PS: please ensure thatfilemap.jsThe file is in the root directory)


node filemap.js <-i folder-name folder-name folder-name ...>
  • < -i folder-name >: in order to hide some directories that contain too many sub-files and sub-folders, for examplenode_modulesFolder, we can use this command to prevent them from expanding. File names are separated by spaces.