Commit Graph

9 Commits

Author SHA1 Message Date
yusing
e31cdde636 fix(scripts): harden update-wiki impl doc sync and GitHub line links
When a path includes a line number, use only the #L anchor in the blob URL
and do not append the old #fragment, which duplicated the anchor in the
href.

Ignore READMEs under scripts/ (alongside submodule paths), read a missing
destination mdx as empty, remove unexpected impl .mdx files when syncing, and
run `main` only when `import.meta.main` so the module is importable from
tests. Export `rewriteImplMarkdown` and `syncImplDocs` and add Bun tests for
link rewriting, scripts exclusion, and add/remove mdx output.
2026-04-23 17:23:39 +08:00
yusing
5d9fe5e2fb chore(scripts): set @types/bun to latest in update-wiki
Point devDependency @types/bun at `latest` and refresh `bun.lock` to
@types/bun@1.3.12 / bun-types@1.3.12 (from 1.3.9).
2026-04-23 17:23:39 +08:00
yusing
26fb99734b chore(make): align minify and update-wiki with Bun package layout
Replace minify-js with minify delegating to `bun scripts/minify`. Add
modernize (go fix per module). Drop echo lines from tidy
and dependency update loops. Rename update-wiki entry to index.ts and
invoke it as `bun scripts/update-wiki`.
2026-04-23 17:23:39 +08:00
yusing
743eb03b27 fix(scripts): correct repo root path in update-wiki
The repoRootAbs was resolving to the script directory instead of the
repository root. Fixed by resolving two levels up from import.meta.dir.

Also optimized writeImplDocToMdx to skip writes when content is unchanged
and removed unused return value from syncImplDocs.
2026-02-24 15:10:03 +08:00
yusing
c2d8cca3b4 refactor(docs): migrate wiki generation to MDX format
- Convert markdown output to  fumadocs MDX
- Add api-md2mdx.ts for markdown to MDX transformation
- Remove sidebar auto-update functionality
- Change output directory from src/impl to content/docs/impl
- Update DOCS_DIR path in Makefile to local wiki directory
- Copy swagger.json directly instead of generating markdown
- Add argparse dependency for CLI argument parsing
2026-02-18 14:05:40 +08:00
yusing
b272f3ffb7 refactor(scripts): enhance update-wiki script directory link resolution with parent fallback
Add fallback logic to rewriteImplMarkdown to traverse parent directories when resolving directory links, allowing paths like "internal/watcher/events" to resolve via their parent "internal/watcher" if no exact match exists. Also update built-in import to use explicit "node:" protocol.
2026-02-16 08:13:47 +08:00
yusing
1a3810db3a fix(scripts/update-wiki): add "internal/go-proxmox/" to skipSubmodules list 2026-01-25 13:51:10 +08:00
yusing
cc1fe30045 refactor(scripts/wiki): rewrite markdown links when syncing impl docs to wiki
- Convert intra-repo README links to VitePress routes for SPA navigation
- Rewrite source file references (e.g., config.go:29) to GitHub blob links
- Makefile now passes REPO_URL to update-wiki for link rewriting
- Correct agent README.md file links from full to relative paths
- skip introduction.md when syncing
2026-01-10 13:54:22 +08:00
yusing
7556a06716 feat(scriptsi): add script to sync implementation docs with wiki
- Introduced a new `update-wiki` script to automate the synchronization of implementation documentation from the repository to the wiki.
- Added necessary configuration files including `package.json`, `tsconfig.json`, and `.gitignore` for the new script.
- Updated the Makefile to include a target for running the `update-wiki` script.
2026-01-08 18:17:06 +08:00