CLI
Commands for initializing, developing, building, and snapshotting Docgo documentation.
The docgo binary provides the project lifecycle commands.
npx docgo [command]docgo init
Creates starter files in the current working directory.
npx @kyechan99/docgo initThe command is non-destructive by default. Existing files are skipped.
Generated files include:
docgo.config.mjshead.htmlpublic/favicon.pngpublic/logo.pngdocs/index.mdx- starter guide pages under
docs/guide
docgo dev
Starts the local development server.
npx docgo devUse this while editing:
- markdown and MDX pages
docgo.config.mjshead.html- theme/navigation settings
- assets referenced from
public
docgo build
Builds the static site.
npx docgo buildThe build command:
- Loads and resolves
docgo.config.mjs. - Removes the output directory.
- Copies
publicassets. - Builds the client bundle.
- Renders every
.mdand.mdxpage to HTML. - Emits markdown mirrors for page actions and AI tools.
- Writes the search index when enabled.
- Writes SEO files when enabled.
docgo version <name>
Snapshots the current default version into a named version folder.
npx docgo version v1If the default version is latest, this copies:
snapshot output
docs/en/latest -> docs/en/v1
docs/ko/latest -> docs/ko/v1The command refuses to overwrite an existing target folder and does not edit
docgo.config.mjs. Add the version to config manually:
versioning: {
defaultVersion: 'latest',
versions: [
{ code: 'latest', label: 'Latest' },
{ code: 'v1', label: 'v1' },
],
}Unknown commands
Unknown commands exit with usage information:
Usage: docgo [build|dev|init|version <name>]