Skip to main content

This is a simple Static Site Generator

Project description

RomanStaticSG

Welcome to Romans Static Site Generator v.0.1

About RomanStaticSG

RomanStaticSG is made in python. It is a simple static site generator. It accepts an input file, or input folder. The current file types that are parsed are text and markdown. Markdown however currently only supports heading level 1 parsing. 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.

How to Use RomanStaticSG

Python 3.9+ Required

Method 1

RomanStaticSG is now released with v1.0.4. To install RomanStaticSG simply enter:

    pip install staticsg-rrezinkin

To use the static site generator, import it as following:

    from staticsg import romanssg
    romanssg.main(sys.argv[1:])

A list of arguments can be found below.

Method 2

Fork and clone this repository. Then execute any of the following commands within the RomanStaticSG folder

python romanssg.py --help

If you run the input command and don't specify the output command, a local folder named "dist" will be created in the directory of the existing file.

!!NOTE!!

If you are executing the following commands from your command line, please navigate to the src/staticg folder, as the commands below expect that you are located in that directory!!

Command List

Help Screen

    python romanssg.py --help  |  python romanssg.py -h  
      
    Help Screen  
    Usage: python romanssg.py
    Commands:
    To get version number use the command: --version, -v
    To change the output directory to a user specified directory, run --output= or -o=
    To specify an input, use either a file or a folder with items inside of it

Version Check

    python romanssg.py --version  |   python romanssg.py -v

    Welcome to the RomanStaticSG, a Static Site Generator  
    The current version is: 1.0.4

Input Command

To run the input command specify the file name with the extension

    python romanssg.py --input=example.txt    |    python romanssg.py --input=example.md

To run the input command with a folder, specify the folder name

For Unix/Linux

    python romanssg.py --input=./someFolder   |   python romanssg.py -i=./someFolder

For Windows

    python romanssg.py --input="C:\Users\Roman Rezinkin\Desktop"    |   python romanssg.py -i="C:\Users\Roman Rezinkin\Desktop"

Output Command

To run the output command specify the custom directory location

For Unix/Linux

    python romanssg.py --output=./someFolder

-OR-

    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"

Code style: black

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

staticsg-rrezinkin-1.0.5.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

staticsg_rrezinkin-1.0.5-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file staticsg-rrezinkin-1.0.5.tar.gz.

File metadata

  • Download URL: staticsg-rrezinkin-1.0.5.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.8.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for staticsg-rrezinkin-1.0.5.tar.gz
Algorithm Hash digest
SHA256 49041e4cc02aa19bfff00ceeb35fa39a5b643eab4ba78d7d00002014208547db
MD5 e12b95a373a2f24b25a4edd43f3dff18
BLAKE2b-256 a152189df9b55e5389341741e448e6152e6f4b1df2328bdcd5dd6c3d8a9b0ceb

See more details on using hashes here.

File details

Details for the file staticsg_rrezinkin-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: staticsg_rrezinkin-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 6.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.8.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for staticsg_rrezinkin-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 58e4683b97282fa8ff8ad832d577a6c1898e5c952d8f9d83be61ec0ee0f3fa8d
MD5 d3f5957c366ceed5808de2347b6b7c0c
BLAKE2b-256 5180db2af5e43a1b4698c17782dc68b3ce0f5152054d111ef701290b97192aaf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page