qmk_firmware icon indicating copy to clipboard operation
qmk_firmware copied to clipboard

Develop some sort of include system for keycode documentation

Open jetpacktuxedo opened this issue 6 years ago • 3 comments

Feature Request Type

  • [ ] Core Functionality
  • [ ] Add-on hardware support (e.g. audio, RGB, OLED screen, etc.)
  • [ ] Alteration (enhancement/optimization) of existing Feature(s)
  • [x] New behavior

Description

As discussed in discord, it would be really nice to have some sort of system for generating https://docs.qmk.fm/#/keycodes and all of the keycodes on the Features pages from a single source. This would help prevent those pages from falling out of sync with one another and make it easier to update with new keycodes.

jetpacktuxedo avatar Dec 12 '18 17:12 jetpacktuxedo

Docsify has an embed feature that allows embedding contents of files into other files.

Example:

Creating a file called "keycodes_modifiers.md", and placing the table with the modifier keycodes in it, would allow for that file to be embedded into the Full List of keys page and the Modifier Keys page.

Reference "keycodes_modifiers.md" in any other file with

[keycodes_modifiers.md](./keycodes_modifiers.md ':include')

This would provide a single source for any given set of keycodes, and would prevent different pages from having different lists of keycodes (like the two pages I linked above).

I've tested this on my branch with the files listed below:

This builds and displays correctly on my system when I run qmk docs and view the local version.

I'd be happy to apply this change to the rest of the keycode types, and submit a PR, if this is good solution for this issue.

jakevandervaate avatar Mar 25 '22 03:03 jakevandervaate

I think this is a step in the right direction. Could you please open the PR? Feel free to ping me on it.

Erovia avatar Mar 25 '22 19:03 Erovia

Hi! Im participating in Hacktoberfest and I'd like to know if this issue is counted in Hacktoberfest and if I can work on it?

Anika-Roy avatar Oct 11 '22 12:10 Anika-Roy

Is there a reason the linked PR stalled? Is this issue looking for a new approach?

3geek14 avatar Aug 15 '23 05:08 3geek14