This application creates article stubs for writing blog posts using Pelican.
Pelican is a static website generator.
This application has reached the point where I am using it to generate article stubs for my blog.
Documentation for Article Generator can be found at Read the Docs.
You run article.py
, fill in a few fields on the form, click the "Create" button. This creates an empty article file you can use to write your blog post.
This allows you to write out several article stubs and once, saving you time and helping you to plan your content more effectively.
- You are using the Pelican static site generator.
- Article categories are folder names inside the content folder.
- The folders 'images', 'pages', and 'static', if found in your content folder, are ignored and not considered categories.
Article files are named with the following format:
YYYY-MM-DD-document-title-separated-by-dashes
Example: 2009-10-14-sugary-pecans-or-walnuts.md
Files are saved with these extensions:
- md: Markdown file
- rst: Restructured text file
Once an article is created, simply open the article in your favorite text editor and replace the "Insert article here" with your own amazing prose.
Sample Markdown Article:
---
Title: Sample Article
Date: 2020-02-21
Category: Technology
Tags: python
Author: shakiestnerd
Status: draft
Summary:
---Insert article here.
To start the development virtual environment, use:
source venv\bin\activate
Note to self:
Look into using Versioneer to maintain the current version
Stored in docs folder.
See Carol Willing talk from Pycon 2018
Commands:
make clean
make build
python3 -m http.server
Open http://localhost:8000/docs/build/html/index.html
To use markdown, use recommonmark
import recommonmark.Parser
# Add a source file parser for markdown
source_parsers = {
'.md': 'recommonmark.parser.CommonMarkParser'
}
# Add type of source files
source_suffix = ['.rst', '.md']
Also using the "sphinx_rtd_theme" theme. See Read the Docs for information.
Thank you