A static site generator that converts markdown files into a served website.
- Converts markdown files to HTML
- Supports nested folder structure for subpages
- Serves the generated site locally
- Copies static assets (images, CSS, etc.)
- Uses customizable HTML template
- Python 3.x
- Required Python packages (installed automatically by the script)
- Clone the repository:
git clone https://github.com/jradziejewski/python_ssg.git
cd python_ssg-
Add your content:
- Place markdown (.md) files in the
contentdirectory - Add static assets (images, CSS, JS) to the
staticdirectory - Customize
template.htmlin root directory to define page layout - Create subdirectories for nested pages if desired
- Example structure:
content/ ├── index.md ├── about.md └── blog/ ├── post1.md └── post2.md - Place markdown (.md) files in the
-
Run the generator:
./main.sh- Access your site:
- Open your browser and navigate to
http://localhost:8888 - Your markdown files will be served as formatted HTML pages
- Open your browser and navigate to
python_ssg/
├── content/ # Place your markdown files here
├── static/ # Static assets (images, CSS, JS)
├── template.html # HTML template for all pages
├── main.sh # Main script to run the generator
└── src/ # Source code for the generator
If you'd like to contribute, please fork the repository and open a pull request to the main branch.