DEV Community

Ririio
Ririio

Posted on • Updated on

Open Source Development Release 0.1

It's been a while since the last time I started coding so it took me a while to get accustomed to using JavaScript again.

The purpose of this release is to add a version, help and input flag for the command line.

I used Commander to allow for custom flags, thankfully it already has a "version" flag in it that I can simply use. Using the "package.json" I can display the current version of my file.

I started implementing the main objective of the program which is to allow the user to convert .txt file into an HTML5. It was fairly difficult to do considering I haven't coded for a few months, but I managed to get back to it after a few hours and finished implementing all the necessary structure.

There are Optional Features of which I must implement at least two of them.

I already finished adding the first implementation which is to implement the title of the .txt to the "title" tag, and to turn it into the most important heading in the body.

I realized that having all the codes into one file can make it cluttered, so I decided to create a secondary js file and insert all the repeated functions there.

I found a partner later on that reviewed my code and found around 7 issues. I managed to fixed them so hopefully the amount of problems lessens.

How to Use

The program's purpose is to allow the user to convert any .txt file to a formatted HTML5.

Flags

The program consists of four flags

Name Command Description Example
Help --help, -H Allows the user to view list of other commands and how they work [node server.js --help]
Version --version, -V Display current version of the program [node server.js --version]
Input --input, -I Convert the a .txt file to an HTML5 formatted file [node server.js --input [filePath]
Output --output, -O Change the directory of where the html file is going to be send to. [node server.js --output [directoryName]

Example of Input

The command line

Image description

The default "dist" directory that contains all the html files of this instance

Image description

The Contents of the HTML5 files

Image description




Contact Information

Email: (mrleonardo@myseneca.ca)

Link to the repository: Ririio-ssg

Top comments (0)