Command line node program for scaffolding out project structures. sfold uses emmet style selectors to create files and folders.
npm install -g sfold and then it will be available
in your terminal as
The expression will be a a string of file and directory names seperated by
>is the child selector. Put it after a directory name to nest files and directories. for example
sfold "server>app.js"would create a folder called "server/" and create a file in it called "app.js" You can nest multiple levels. It is also possible to create folders without the child selector by just putting a "/" on the end of file name.
+is the sibling selector. Put it after a file or directory to put it in the same folder as the previous item. For example,
sfold "routes/+main.js+style.css"would create a "routes" folder, a "main.js" file, and a "style.css" file all in the root directory wherever
^is the parent selector. Use it inside of a nested folder to jump up one level and then keep inserting files. For example
sfold "server>main.js^index.html"would create a "server" folder and an "index.html" file in the root directory and a "main.js" file in the server folder.
This is an example of what a common use might look ilke.
Which would create a file structure that looks like this.
main.js README.md routes/ models/ └ user.js public └ index.html └ styles/ └ main.css
If you have any issues or questions please let me know.