What I am missing about taxonomy for this to work?

I am working on a workflow generated content based website to show in a more user friendly way what is the state of nixpkgs packages. I am now testing with sample content so when I get the template right I only have to make the script to fetch stuff and create the content files and package it in a workflow to run as a cron job.

But the issue is that the taxonomy pages list the “tags” but do not list the posts which reference the tags. I don’t know what to try next to fix it.

Repo: GitHub - lucasew/nixpkgs-maintainer-dashboard: Proof of concept of an information concentrator that shows information about the state of packages in nixpkgs and shows it as a static site

First, you need to add “tags” to your taxonomies:

[taxonomies]
build_state = 'build_states'
maintainer = 'maintainers'
tag = 'tags'
update_state = 'update_states'

Second, the directory names for your taxonomy content files must be the plural form:

content/
├── build_states/   <-- PLURAL NOT SINGULAR
│   ├── ok/
│   │   └── _index.md
│   └── _index.md
├── maintainers/   <-- PLURAL NOT SINGULAR
│   ├── lucasew/
│   │   └── _index.md
│   └── _index.md
├── package/
│   ├── python3Packages/
│   │   ├── bentoml/
│   │   │   └── _index.md
│   │   └── _index.md
│   ├── _index.en.md
│   └── _index.pt.md
├── update_states/   <-- PLURAL NOT SINGULAR
│   ├── ok/
│   │   └── _index.md
│   └── _index.md
└── _index.md

Third, your site config needs a lot of love: remove the mounts, don’t disable taxonomy and term pages, add language weights, etc.

baseURL = 'https://example.org/'

[languages.en]
disabled = false
languageCode = 'en-US'
languageName = "🇺🇸"
title = "nixpkgs maintainers dashboard"
weight = 1

[languages.pt]
disabled = false
languageCode = "pt-BR"
languageName = "🇧🇷"
title = "dashboard dos mantenedores do nixpkgs"
weight = 2

[taxonomies]
build_state = 'build_states'
maintainer = 'maintainers'
tag = 'tags'
update_state = 'update_states'

[markup.goldmark.renderer]
unsafe= true

After making the changes above and building your site, I visited the “tags” taxonomy page:
http://localhost:1313/tags/

This page displays a list of tags:

Then I visited the “Teste” term page:
http://localhost:1313/tags/teste/

This page displays a list of pages where the “Teste” tag is present in front matter:

It all looks right to me.

Thank you. It works now. This mount thing is to reuse one markdown in multiple languages. bep himself suggested this and that’s what I use for some utility routes in my blog. BTW this template is based on my site’s template.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.