all repos — py-vite @ f45e3de024c6abb079ba4a537e0d03f86070d329

the original vite, written in python

docs: create README.rst and MANIFEST.ini
icyphox icyph0x@protonmail.com
Wed, 21 Mar 2018 13:28:59 +0530
commit

f45e3de024c6abb079ba4a537e0d03f86070d329

parent

df4d0d1f6ecd13d9d8fc247c9f78f3bc6666bfd3

2 files changed, 96 insertions(+), 0 deletions(-)

jump to
A MANIFEST.ini

@@ -0,0 +1,1 @@

+include README.rst
A README.rst

@@ -0,0 +1,95 @@

+.. raw:: html + + <h1 align="center"> + +:: + + <img width="400" src="https://xix.ph0x.me/vitelogo.png" alt="Vite"> + +.. raw:: html + + </h1> + + A simple and mnml static site generator; pronounced as /vit/ + +Usage +----- + +.. code:: console + + $ vite.py new <project-path> + +Write your Markdown files in the ``pages`` directory and execute + +.. code:: console + + $ vite.py build <project-path> + +**OR** + +.. code:: console + + $ make.py # at the project directory + +Rendered HTML will be in the ``build`` directory. + +Configuration +------------- + +Not very sophisticated, but basic configuration can be acheived using +``config.py`` found in the project directory. Example config: + +.. code:: python + + # config.py + title = '' + author = '' + header = '' + footer = '' + +Templating +---------- + +Vite uses Jinja2 templating. A basic example would be: + +.. code:: html + + <title> {{ title }} </title> + + <body> + {{ body }} + </body> + + <footer> + {{ footer }} + </footer> + +Directory tree +-------------- + +:: + + example + ├── build + │   └── test_page1 + │   └── index.html + ├── config.py + ├── make.py -> /home/icyphox/code/vite/make.py + ├── pages + │   └── test_page1.md + └── templates + └── index.html + +TODO +---- + +- [x] Templating +- [ ] CSS support +- [ ] Implement a simple HTTP server (*later*) +- [x] Add example site +- [x] Basic config (``config.py``) + +Credits +------- + +*Logo credits*: Freepik from www.flaticon.com is licensed by CC 3.0 BY