{
  "description": "Switch to or create a worktree, list worktrees, or remove one. Hooks, the interactive picker, PR/MR shortcuts and config subcommands are left to the command line.",
  "name": "wt",
  "subcommands": [
    {
      "name": "switch",
      "description": "Go to the worktree for a branch, optionally creating the branch from a base.",
      "options": [
        {
          "names": [
            "--create",
            "-c"
          ],
          "description": "Create new branch"
        },
        {
          "names": [
            "--base",
            "-b"
          ],
          "description": "Branch to start the new branch from; defaults to the default branch.",
          "args": {
            "name": "base",
            "description": "Branch to start the new branch from; defaults to the default branch.",
            "isOptional": false
          }
        },
        {
          "names": [
            "--execute",
            "-x"
          ],
          "description": "Run program after switch",
          "args": {
            "name": "execute",
            "isOptional": false
          },
          "isDangerous": true
        },
        {
          "names": [
            "--no-cd"
          ],
          "description": "Do not change directory"
        },
        {
          "names": [
            "--no-hooks"
          ],
          "description": "Skip hooks"
        },
        {
          "names": [
            "--clobber"
          ],
          "description": "Remove stale path at target",
          "isDangerous": true
        }
      ],
      "args": [
        {
          "name": "branch",
          "description": "Branch name or worktree path. Shortcuts: ^ (default branch), - (previous), @ (current).",
          "isOptional": true
        }
      ]
    },
    {
      "name": "list",
      "description": "Show worktrees and their status.",
      "options": [
        {
          "names": [
            "--format"
          ],
          "description": "Output format",
          "args": {
            "name": "format",
            "isOptional": false,
            "suggestions": [
              {
                "name": "table",
                "description": "Table"
              },
              {
                "name": "json",
                "description": "JSON"
              }
            ]
          }
        },
        {
          "names": [
            "--branches"
          ],
          "description": "Include branches without worktrees"
        },
        {
          "names": [
            "--remotes"
          ],
          "description": "Include remote branches"
        },
        {
          "names": [
            "--full"
          ],
          "description": "Also queries the forge over the network."
        }
      ]
    },
    {
      "name": "remove",
      "description": "Remove worktrees and delete their branches when merged. Defaults to the current worktree.",
      "options": [
        {
          "names": [
            "--no-delete-branch"
          ],
          "description": "Keep the branch"
        },
        {
          "names": [
            "--force-delete",
            "-D"
          ],
          "description": "Delete unmerged branches",
          "isDangerous": true
        },
        {
          "names": [
            "--force",
            "-f"
          ],
          "description": "Force removal of a dirty worktree",
          "isDangerous": true
        },
        {
          "names": [
            "--foreground"
          ],
          "description": "Wait for removal"
        },
        {
          "names": [
            "--no-hooks"
          ],
          "description": "Skip hooks"
        }
      ],
      "args": [
        {
          "name": "branches",
          "description": "Leave empty to remove the current worktree.",
          "isOptional": true,
          "isVariadic": true
        }
      ]
    }
  ]
}
