Skip to content

IvaniGabrovsky/text-ssg-tool

Repository files navigation

text-ssg-tool

A Cli tool reading an file with text and converting to an out file in html using Node.js.

Installation

Install the dependencies:

npm i

Usage

To get a list of options type "text-ssg-tool" followed by -h.
For any of the commands listed below in the help menu type in "text-ssg-tool" before the command.

Options

  1. node src/index.js --help or node src/index.js -h to display the usage information

  2. Run node src/index.js --version or node src/index.js -v to display the tool name and version

  3. Run node src/index.js -i [name of the file] to convert file from markdown or text to html.

  4. Run node src/index.js -l [language] -i [name of the file] to convert file from markdown or text to html.

  5. Run node src/index.js -i [name of the file] -l [language] to convert file from markdown or text to html.

Examples

  1. node src/index.js -i input/inputMD.md (convert a markdown file inside input folder into html)

  2. node src/index.js -i input/text.txt (convert a text file inside input folder into html)

  3. node src/index.js -i input/Sherlock-Holmes-Selected-Stories (convert all files inside input folder inside Sherlock-Holmes-Selected-Stories into html)

  4. node src/index.js -l fr -i input/Sherlock-Holmes-Selected-Stories (convert all files inside input folder with french language inside Sherlock-Holmes-Selected-Stories into html)

  5. node src/index.js -i input/Sherlock-Holmes-Selected-Stories -l fr (convert all files inside input folder with french language inside Sherlock-Holmes-Selected-Stories into html)

Test Site

https://ivan-text-ssg-tool.netlify.app/

License

[**MIT License**](https://choosealicense.com/licenses/mit/)