Web Feeds
Description
The Sine Die theme allows you to generate RSS and Atom web feeds for your Hugo website.
Configuration
Some changes are needed to the configuration of your Hugo website.
- Add
application/atom+xmlto mediaTypes - Add
atomto outputFormats (also changebaseNameforrssfor consistency) - Add
atomandrssto outputs for each page kind on which you want to enable web feed generation
If you are using a
configuration directory,
you can copy mediaTypes.yaml, outputFormats.yaml, and outputs.yaml from
userguide/config/_default.
Here are the changes to make to hugo.yaml:
1mediaTypes:
2 application/atom+xml:
3 suffixes:
4 - xml
5
6outputFormats:
7 atom:
8 baseName: index.atom
9 mediaType: application/atom+xml
10 noUgly: true
11 rss:
12 baseName: index.rss
13
14outputs:
15 # Enable web feeds on homepage
16 home:
17 - html
18 - atom
19 - rss
20 # Individual pages do not have web feeds
21 page:
22 - html
23 # Enable web feeds on sections
24 section:
25 - html
26 - atom
27 - rss
28 # Enable web feeds on taxonomies (e.g., tags and categories)
29 taxonomy:
30 - html
31 - atom
32 - rss
33 # Enable web feeds on taxonomy terms (e.g., each tag and category)
34 term:
35 - html
36 - atom
37 - rss