Few steps for Node file manipulation example.
If you need help, call me: Twitter, Medium
- SublimeText or other file editor
- NPM
- Node JS
Fist, install NPM for Node.JS managing packages. ( Just make sure, this is a Ubuntu example )
sudo apt-get install npm
Then, install Node.js
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
Download the project, and inside the folder, just run for dependences installation
$ npm install
For testing, I created a file for each operation example.
For creating a new file, read the createFile.js for some consideration, or simple open your favorite Terminal and run this command and check the FILES folder.
$ node createFile
For deleting a file, read the deleteFile.js for some consideration, or place one or multiple files in the FILES folder and simple open your favorite Terminal and run this command.
$ node deleteFile
For reading a file, read the readFile.js for some consideration, or place the file in the FILES folder and simple open your favorite Terminal and run this command and wait for the result in the console.
$ node readFile
For renaming a file or a lot of, read the renameFiles.js for some consideration, or place one or multiple files in the FILES folder and simple open your favorite Terminal and check the FILES folder.
$ node renameFiles
Give me some ideias :P
MIT Free Software, Free Examples, Free hugs!