Skip to content

Commit 0d9a828

Browse files
committed
Update docs and bump version to 25.9
1 parent 9f068c7 commit 0d9a828

File tree

3 files changed

+42
-8
lines changed

3 files changed

+42
-8
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@
22

33
All notable changes to the genja project are documented in this file. The format of this changelog is based on [Keep a Changelog](https://keepachangelog.com). This project adheres to [Calendar Versioning](https://calver.org) based on `YY.MM.MICRO`.
44

5+
## Genja v25.9
6+
7+
#### Added
8+
9+
- Examples to demonstrate new and updated features
10+
- Documentation for the new examples
11+
512
## Genja v25.8
613

714
#### Added

docs/examples.rst

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,25 +54,52 @@ The ``directory-output`` example defines ``site_output = "mysite"`` in the ``gen
5454
HTML content
5555
------------
5656

57-
The ``html-content`` example demonstrates putting HTML in the Markdown file.
57+
The ``html-content`` example demonstrates putting HTML in the Markdown file. The ``about.md`` in the example uses the ``<figure>`` element to display an image with a caption.
58+
59+
.. code:: html
60+
61+
<figure>
62+
<img src="images/homer-simpson.jpg" alt="Homer Simpson" />
63+
<figcaption>An image of Homer Simpson is in this figure.</figcaption>
64+
</figure>
65+
66+
The same is done in the ``apple.md`` post but notice the path to the image file is adjusted for the post.
67+
68+
.. code:: html
69+
70+
<figure>
71+
<img src="../images/apple.jpg" alt="an apple" />
72+
<figcaption>This is an image of an apple.</figcaption>
73+
</figure>
5874

5975
Image files
6076
-----------
6177

62-
The ``image-files`` example shows how to embed images in the Markdown file.
78+
The ``image-files`` example shows how to embed images in the Markdown file. This is accomplished as shown below but notice the path to the image file may vary for pages and posts.
79+
80+
.. code:: markdown
81+
82+
![Homer Simpson](images/homer-simpson.jpg)
6383
6484
Pages and posts
6585
---------------
6686

67-
The ``pages-and-posts`` examples demonstrates creating pages and posts as Markdown files.
87+
The ``pages-and-posts`` examples demonstrates creating pages and posts as Markdown files. Pages reside in the ``_pages`` directory while posts reside in the ``_posts`` directory.
6888

6989
Root output
7090
-----------
7191

72-
The ``root-output`` example generates the HTML website content at the root level of the project.
92+
The ``root-output`` example generates the HTML website content at the root level of the project. This is defined in the ``genja.toml`` config file by setting the ``site_output`` to the current working directory as shown below:
93+
94+
.. code:: toml
95+
96+
base_url = "https://example.com"
97+
posts_output = "blog"
98+
site_output = "."
99+
title = "My Website"
73100
74101
Sort posts
75102
----------
76103

77-
The ``sort-posts`` example sorts the posts.
104+
The ``sort-posts`` example shows how to sort posts by date, category, or tag. A demonstration of sorting only recent posts is also given. This is accomplished with the Jinja template engine. See the `Template Designer Documentation <https://jinja.palletsprojects.com/en/stable/templates/>`_ for more information about creating Jinja templates.
78105

docs/index.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
Genja Documentation
2-
===================
1+
Welcome to Genja
2+
================
33

4-
Genja is a simple static website generator. It is a command line tool built in Python that generates HTML files and a JSON feed from Markdown content. The source code for Genja is available on `GitHub <https://github.com/wigging/genja>`_.
4+
Welcome to Genja's documentation. Genja is a simple static website generator. It is a command line tool built in Python that generates HTML files and a JSON feed from Markdown content. The source code for Genja is available on `GitHub <https://github.com/wigging/genja>`_.
55

66
.. toctree::
77
:maxdepth: 2

0 commit comments

Comments
 (0)