Skip to content

Adding docmd#8

Open
Tiltann wants to merge 14 commits intoSamMethot:mainfrom
Tiltann:main
Open

Adding docmd#8
Tiltann wants to merge 14 commits intoSamMethot:mainfrom
Tiltann:main

Conversation

@Tiltann
Copy link
Copy Markdown

@Tiltann Tiltann commented May 9, 2026

Pull Request

What This Changes

This PR adds docmd as the static site generator for this repo and wires up GitHub Pages deployment. It configures the navigation tree to mirror the existing folder structure (01-basics → 10-first-projects), sets a theme, enables the git plugin (edit links, last-updated, recent commits), and ships the footer. It also sets up a prebuild step so README.md becomes the published site's homepage, which removes the duplication between the GitHub repo readme and a separate docs landing page. INDEX.md is renamed to FULL-INDEX.md because docmd reserves index.md for the homepage path.

Type Of Change

  • Typo / broken link / formatting
  • Bug fix in an example
  • Outdated API reference
  • New lesson or section
  • Improved example (clearer / shorter / more correct)
  • Other (explain below)

Other:

  • Documentation tooling and deploy infrastructure: adds docmd, configures the published site, and adds a GitHub Actions workflow that publishes to GitHub Pages on push to main.

Lesson(s) Affected

  • docmd.config.js (new)
  • package.json / package-lock.json (new / updated)
  • .github/workflows/ (new - GitHub Pages build + deploy)
  • INDEX.md → FULL-INDEX.md (renamed)
  • README.md (added a link to the published docs site)
  • .lycheeignore (added the github.io URL so the link checker doesn't fail before the first deploy)

Testing

  • I tested the code on a dev server
  • The code matches the line-by-line annotation style of the rest of the repo
  • All ? placeholders are used in SQL (no string concat)
  • Any net event examples include source caching + arg validation
  • Doc links resolve

Tone Check

  • Plain-English summary at the top of any new lesson
  • Every non-trivial Lua line is annotated
  • TL;DR section at the bottom
  • Next: pointer at the end if it is a numbered lesson
  • No filler / marketing speak / unnecessary emoji
  • Doc links go to canonical sources (FiveM docs, coxdocs.dev, docs.qbox.re)

The lesson-style items don't apply — this PR is tooling and config, not lesson content.

Updated Index?

  • Updated INDEX.md if I added or renamed files
  • N/A - did not change file structure

INDEX.md was renamed to FULL-INDEX.md so docmd's homepage convention (index.md) doesn't collide with the manual table-of-contents file. The full index is now reachable at /full-index on the deployed site.

Additional Notes

  • docmd was chosen because it's zero-config, outputs plain static HTML with no framework runtime, and auto-generates llms.txt so the docs are AI-readable by default.
  • The prebuild script copies README.md → index.md before each build, so the README is the single source of truth for both the GitHub repo page and the published site's homepage. index.md is gitignored so it never drifts.
  • Navigation in docmd.config.js mirrors the existing 01-basics → 10-first-projects folder structure with per-section Lucide icons.
  • The GitHub Actions workflow runs npm ci && npm run build and publishes the site/ output to GitHub Pages on push to main.
  • The new GitHub Pages URL was added to .lycheeignore so the link checker doesn't fail on a freshly forked clone before the first deploy.

Important Note

To make this work you need to change the Repository Settings

Settings -> Pages -> Source to "Github Actions"

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.

1 participant