RomanStaticSG
Roman Rezinkin
Posted on September 17, 2021
RomanStaticSG is a static site generator. It is simple to use, yet very effective.
About RomanStaticSG
RomanStaticSG is made in python. It is a simple static site generator. It accepts an input file, or input folder. The program will then take the accepted files and create basic html webpages, as well as an index.html file. The script also allows you to input a custom output directory, so that the files could be saved in a custom location.
Currently only .txt files work
What is a Static Site Generator (SSG)
A static site generator is a tool that generates full blown static HTML websites from raw data and some templates. The point of a static site generator is to quickly convert a document file or a text file into a working webpage, that is filled with content.
How to Use RomanStaticSG
Python 3.9+ Required
To use RomanStaticSG simply type
python romanssg.py --help
Some Commands in RomanStaticSG
Help Screen
python romanssg.py --help | python romanssg.py -h
Version Check
python romanssg.py --version | python romanssg.py -v
Input Command
To run the input command specify the file name without the extension
python romanssg.py --input=example | python romanssg.py -i=example
When running the input command and not specifying the output command, a local folder named "dist" will be created in the directory of the existing file.
Output Command
To run the output command specify the custom directory location
For Unix/Linux
python romanssg.py --output=./someFolder | python romanssg.py -o=./someFolder
For Windows
python romanssg.py --output="C:\Users\Roman Rezinkin\Desktop" | python romanssg.py -o="C:\Users\Roman Rezinkin\Desktop"
Conclusion
Although the task seemed taunting at first, I was able to quickly understand what I had to do. As a relatively new developer with Python, I had to make some academic searches for syntax and general knowledge on Python. This challenge only made the development of this tool that more entertaining.
Github Repository: https://github.com/roman-rezinkin/RomanStaticSG
Sample Output Website: https://roman-rezinkin.github.io/RomanStaticSG/demo/
Posted on September 17, 2021
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.