static.py logo

static.py

is (yet another) static blog/page/singlepage generator for python.

But I think it has quite a few nice features to make you up and running out of the box. The most handy is IMHO that you can comment static post with twitter. The next time you generate the blog the comments are collected and rendered automatically. You can also update and render the blog in the backend every some minutes to be more up-to-date.

if you want to make a blog or single page => you're done! (batteries included ;)

unique features

  • comment posts via twitter ..* so no third party tool or login required for comments. ..* comments are collected automatically from twitter next time you generate the blog.

  • pre rendered tag views on board (click on a tag and you see all posts with that tag)

features

  • supports blogs, pages, posts and single pages
  • tagging on board
  • tag cloud on board (see snapshots below)
  • simple pagination (newer, older) on board
  • syntax highlighting with highlight.js on board
  • charts.js on board and usable in the posts / pages directly
  • d3.js demo with loading data from csv file on board.
  • everthing in posts and pages is markdown
  • you can add your own javascript or css in every post or template
  • pre_rederers: call any of your own python functions before rendering
  • based on bootstrap4
  • very sophisticated template engine based on tornado {{val}}
  • image gallery on board
  • ready to be hosted on github pages (as this site is)

the goal is to make you just run in a second if you wish to make

  • a blog
  • a single page or landing page
  • specific pages for a topic including charts, articles.

workflow

  1. (generate your site)

     python generate_site.py (or just copy the dirs for now)
    
  2. write a post or page (markdown text). The example below is this exactr page you can see right now

    page example

  3. generate the blog

    python generate_blog.py
    
  4. run test_server (if happy copy to your server, webhoster or github

  5. done

looks like this with the default theme (bs4_blog)

static<em>blog</em>post_example