GenderDysphoria / GenderDysphoria.fyi

Site code
Other
228 stars 61 forks source link

Navigation checking script #39

Closed ScoreUnder closed 3 years ago

ScoreUnder commented 3 years ago

A little maintenance script (about a 7 out of 10 on the hacky-o-meter) to keep the navigation in the dropdown, the index.md ToC, and the prev/next buttons consistent.

It might be a little overkill, I'm not sure. It uncovers some inconsistencies like /gdb/causes's "next" button saying But... but... the chromosomes!, and /gdb/hormones's "prev" button saying Chromosomes. It wants to overwrite many of the prev/next links though, because they aren't the same as the usual navigation text.

Usage: cd tools && ./navigation.py to just check, or cd tools && ./navigation.py --write to write changes to each file. (Changes can then be picked out with git add -p or similar)

Requires python 3 and libyaml for python (usually called python-yaml or python3-yaml in whatever package manager you use).

Twipped commented 3 years ago

Thanks! I'll eventually replace the python script with part of the build process, but the linkTitle meta tag is an excellent addition.