Skip to content

Normalize post tags to a single lowercase, dashed form - #105

Merged
ultimatecoder merged 1 commit into
masterfrom
fix/normalize-tag-names
Aug 6, 2026
Merged

Normalize post tags to a single lowercase, dashed form#105
ultimatecoder merged 1 commit into
masterfrom
fix/normalize-tag-names

Conversation

@ultimatecoder

Copy link
Copy Markdown
Owner

Context

Jekyll passes each tag from post front matter straight through to the generated /tags/<tag>/ path. Tags were written inconsistently across posts, so on the Linux runner that builds the site this produces separate pages for tags meant to be the same.

Live on production right now:

URL Status
https://blog.jaysinh.dev/tags/Python/ 200
https://blog.jaysinh.dev/tags/python/ 200
https://blog.jaysinh.dev/tags/CorePython/ 200
https://blog.jaysinh.dev/tags/python%20trick%20questions/ 200

The Python posts are split across two indexes, and one URL carries raw spaces.

Worth noting for anyone verifying locally: a macOS build hides the split, because the case-insensitive filesystem collapses Python/ and python/ into a single directory. The bug only appears on the case-sensitive CI runner — which is the build that actually deploys.

Change

Front matter only, 11 posts. Every tag normalized to lowercase with dashes as the separator:

Python, CorePython, Python3.7  ->  python, core-python, python-3-7
Ubuntu, GRUB, How-to           ->  ubuntu, grub, how-to
ILUG-C                         ->  ilug-c
goyo_doc                       ->  goyo-doc
python trick questions         ->  python-trick-questions

Also settles the front matter key on tags:, replacing the tag: spelling some posts used. Jekyll pluralizes both into site.tags, so this changes no output — but the inconsistency is what made the drift easy to miss in the first place.

No plugin or layout changes. This is a one-time content cleanup; the convention will be written into the README and the PR checklist rather than enforced by code.

Verification

./scripts/test (build + htmlproofer) passes. Generated tag directories after the change:

books  conference  core-python  django  djangogirls  docker  goyo-doc
grub  how-to  ilug-c  linux  programming  python  python-3-7
python-trick-questions  pythonexpress  slice  talks  ubuntu  vim  workshop

No uppercase letters, no spaces. Every link on /tags/ resolves.

Note on existing URLs

The old mixed-case paths will 404 after this merges. They were duplicate or malformed indexes rather than pages worth preserving, and every tag keeps a working URL under its normalized name. Flagging it explicitly in case you would rather add jekyll-redirect-from first.

Closes #76

🤖 Generated with Claude Code

Tags were written inconsistently across posts, and Jekyll passes each one
through to the generated `/tags/<tag>/` path verbatim. On the Linux runner
that builds the site this produced separate pages for tags that are meant
to be the same: `/tags/Python/` and `/tags/python/` are both live today,
splitting the Python posts across two indexes. A local build on macOS hides
this, because the case-insensitive filesystem collapses the two directories
into one.

It also produced `/tags/python trick questions/`, a URL carrying raw
spaces.

Normalize every tag to lowercase with dashes as the separator:

  Python, CorePython, Python3.7 -> python, core-python, python-3-7
  Ubuntu, GRUB, How-to          -> ubuntu, grub, how-to
  ILUG-C                        -> ilug-c
  goyo_doc                      -> goyo-doc
  python trick questions        -> python-trick-questions

Also settle the front matter key on `tags:`, replacing the `tag:` spelling
some posts used. Jekyll pluralizes both into `site.tags`, so this changes
no output, but the inconsistency is what made the drift easy to miss.

The old mixed-case paths will 404 after this. They were duplicate or
malformed indexes rather than pages worth preserving, and each tag keeps a
working URL under its normalized name.

Closes #76

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@ultimatecoder
ultimatecoder force-pushed the fix/normalize-tag-names branch from 9bbd0dd to 813f31c Compare August 6, 2026 14:11
@ultimatecoder
ultimatecoder merged commit 92a4548 into master Aug 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix issue of case sensitive tags

1 participant