Skip to content

CLI Command Reference

Complete reference for the WDG CLI.

Basic Usage

bash
wdg <command> [options]

Two grammars exist:

  • Top-level commands: wdg <command> (e.g. wdg start, wdg index, wdg doctor).
  • Project commands: wdg <project> <command> — project-first (e.g. wdg my-site db export, wdg my-site wp plugin list). See Project Commands.

Ports are configurable

The ports below come from .env.defaults (the canonical defaults). They can be overridden in .env, and you can discover the active values at any time with wdg ports.

Project Lifecycle

create

Create a new WordPress project.

bash
wdg create <project-name> [options]

Options:

  • --init-wikit — initialize a new Wikit wp-content repository structure
  • --clone-repo=<url> — clone an existing wp-content repo into the project
  • --remote[=org] — add a GitHub remote and push the initial commit (default org: wdgdc)
  • --template=<name> — project template (default: wikit-base)
  • --php=<version> — PHP version: 8.0, 8.1, 8.2, 8.3, 8.4, 8.5
  • --no-start — create the project but don't start it
  • --skip-build — skip the initial asset build
  • --skip-index — skip the initial code index
  • --skip-default-mcps — skip default MCP configuration
  • --skip-default-skills — skip installing default Claude Code skills
  • --production-url=<url> — record the production URL in the manifest
  • --client=<name> — manifest client name
  • --jira=<key> — manifest Jira project key
  • --hosting-platform=<platform> — manifest hosting platform
  • --hosting-site=<site> — manifest hosting site

Examples:

bash
# Wikit theme only (default)
wdg create my-site

# Managed wp-content repository
wdg create my-site --init-wikit

# With GitHub remote
wdg create my-site --init-wikit --remote

# Clone an existing client repository
wdg create my-site --clone-repo=https://github.com/client/wp-content

# Specific PHP version, prefilled manifest
wdg create client-site --init-wikit --php=8.1 --client="Acme" --jira=ACME --hosting-platform=pantheon --hosting-site=acme-live

start / stop / restart

bash
wdg start [project]      # start core services, or a specific project
wdg stop [project]       # stop core services, or a specific project
wdg restart [service|project]   # restart core services, a service, or a project

Core services: Qdrant (vector DB), MySQL, nginx proxy, MCP server (and, for a project, its WordPress container).

delete

Delete a project and all of its data.

bash
wdg delete <project> [--force]

--force skips the confirmation prompt. Removes project files, database, SSL certificates, nginx configuration, and the project's vector collection.

🚨 DANGER

This cannot be undone. All project data is permanently deleted.

list

List all projects with status and URLs.

bash
wdg list
WDG AI Projects
  ● my-site (running)
     URL: https://my-site.localhost:6443
     Repositories: 2
  ○ another-site (stopped)
     Repositories: 1

System Management

status

Show status of all core services and projects.

bash
wdg status

doctor

Run comprehensive health checks.

bash
wdg doctor                 # platform-wide diagnostics
wdg <project> doctor        # per-project diagnostics
wdg <project> doctor --fix  # diagnose and auto-repair partial state

logs

Tail logs for core services.

bash
wdg logs [service]

For rich, filterable per-project logs (debug, php, nginx, container, all with --follow, --tail=N, --since=, --grep=), see Project Commands.

ports

Show and manage configured service ports.

bash
wdg ports          # show configured ports
wdg ports check    # check for port conflicts
wdg ports status   # show port status
wdg ports find     # find available ports
wdg ports test     # test port reachability

cd

Print a project/repository path for quick navigation.

bash
wdg cd [project] [repo]
wdg cd --setup        # install the `wcd` shell function for real directory changes

Updates

update

Update the Wikit framework repositories and re-index.

bash
wdg update

self-update

Update the platform core (MCP server, indexer, CLI, Docker configs).

bash
wdg self-update              # update the platform
wdg self-update --check      # check for updates
wdg self-update --dry-run    # show what would change
wdg self-update --rollback   # roll back to the last backup

AI & Indexing

index

Index code into the vector database for AI search.

bash
wdg index [project|--platform]
  • No argument — index the Wikit framework (wdg_framework)
  • <project> — index a project's repositories (project_<name>)
  • --platform — index the platform codebase (platform)

Examples:

bash
wdg index               # Wikit framework
wdg index my-site       # a project
wdg index --platform    # platform code

collections

Manage vector database collections.

bash
wdg collections <list|delete|validate|clean>

See Collection Management for details.

Integrations & Tools

mcp

Manage the MCP auth proxy for OAuth-protected services (Atlassian, Figma, Read.ai, Slack).

bash
wdg mcp list              # list configured services
wdg mcp status            # show token validity
wdg mcp auth <service>    # authenticate a service (opens browser)

skills

Sync project skill templates to projects.

bash
wdg skills list                          # list available skill templates
wdg skills sync [skill] [--force]        # sync to every project
wdg skills sync [skill] --project=NAME   # sync to one project

Per-project form: wdg <project> skills sync [skill] [--force].

ai-config

Sync AI assistant configuration and agents to projects.

bash
wdg ai-config sync [--force]             # sync to every project
wdg ai-config sync --project=NAME        # sync to one project

Per-project form: wdg <project> ai-config sync [--all] [--force].

figma

Figma integration.

bash
wdg figma auth        # authenticate (alias: login)
wdg figma refresh     # refresh credentials
wdg figma status      # show auth status
wdg figma logout      # log out
wdg figma me          # show the authenticated user
wdg figma screenshot  # capture a node screenshot
wdg figma export      # export assets
wdg figma metadata    # fetch file metadata
wdg figma nodes       # list nodes
wdg figma pages       # list pages

bugherd

BugHerd integration for feedback management.

bash
wdg bugherd <project> [options]

playwright

Playwright browser automation tooling.

bash
wdg playwright install   # install browsers
wdg playwright test      # run tests

The per-project form is wdg <project> playwright.

Project Commands (summary)

These all use the project-first grammar; see Project Commands for the full reference.

bash
wdg <project> dev | build | lint | analyze
wdg <project> php [set <ver>|available]
wdg <project> repo <add|remove|list|attach|sync|status|hooks|init>
wdg <project> db <export|import|reset|search-replace>
wdg <project> service <add|remove|list>
wdg <project> wp <wp-cli-command>
wdg <project> sync <pantheon|wpvip> [options]
wdg <project> index
wdg <project> logs [debug|php|nginx|container|all] [--follow|--tail=N|--since=|--grep=]
wdg <project> manifest <init|show|get|set|edit>
wdg <project> memory <init|status|reset|export|import>
wdg <project> mcp | skills | ai-config | playwright
wdg <project> rebuild | doctor [--fix]

Environment Variables

Set these in .env (seeded from .env.defaults on install — there is no .env.example):

bash
# Local embedding model (free — no API keys needed for indexing)
EMBEDDING_MODEL=all-MiniLM-L6-v2

# Database credentials
MYSQL_ROOT_PASSWORD=root
WP_DB_USER=wordpress
WP_DB_PASSWORD=wordpress

# Optional: Claude Desktop integration
ANTHROPIC_API_KEY=sk-ant-...

Indexing uses a local sentence-transformers model and needs no OpenAI key.

Service Ports & URLs

Default ports (from .env.defaults; override in .env, discover with wdg ports):

ServiceHost Port
Nginx HTTP6080
Nginx HTTPS6443
MySQL6306 (container 3306)
phpMyAdmin6081
Qdrant HTTP6333 (gRPC 6334)
Indexer6666
MCP server6765
MCP auth proxy6766
Docs site6173
Dashboard frontend6300
Dashboard backend6001

Project URLs: https://<project>.localhost:6443WordPress admin login: wdg / wdg

Global Installation

bash
sudo ln -s $(pwd)/cli/wdg /usr/local/bin/wdg

Bash Completion

Add to your .bashrc or .zshrc:

bash
# WDG CLI completion
_wdg_completion() {
    local commands="create start stop restart delete list status logs index update self-update collections mcp ai-config skills cd doctor ports figma bugherd playwright help"
    COMPREPLY=($(compgen -W "$commands" -- "${COMP_WORDS[1]}"))
}
complete -F _wdg_completion wdg

Docker Commands

bash
# See all WDG containers
docker ps | grep wdg

# Access MySQL
docker exec -it wdg-mysql mysql -uroot -proot

# Access a project's WordPress container
docker exec -it wdg-wp-my-site bash

# View Qdrant dashboard
open http://localhost:6333/dashboard

Getting Help

bash
wdg help        # full command reference
wdg --version   # show version

Need more help? Run wdg help for the authoritative command reference.