{
  "id": "gh",
  "name": "GitHub CLI",
  "homepage": "https://cli.github.com",
  "description": "GitHub on the command line: pull requests, issues and releases without leaving the terminal.",
  "icon": "theSVG:github",
  "executables": [
    "gh"
  ],
  "dotfiles": {
    "paths": [
      "~/.config/gh/config.yml",
      "~/.config/gh/hosts.yml",
      "%APPDATA%/GitHub CLI/config.yml",
      "%APPDATA%/GitHub CLI/hosts.yml"
    ],
    "exclude": [],
    "secret": [],
    "side_effect": false,
    "secret_paths": [
      {
        "file": [
          "~/.config/gh/hosts.yml",
          "%APPDATA%/GitHub CLI/hosts.yml"
        ],
        "match": {
          "key_path": [
            "*.oauth_token",
            "*.users.*.oauth_token"
          ]
        }
      }
    ]
  },
  "commands": {
    "format": 1,
    "label": "GitHub CLI",
    "description": "Work with pull requests, issues and repositories on GitHub. Only list, create and clone are covered; the api, auth, workflow, codespace and project commands are left out.",
    "quality": "ai-draft",
    "base": "fig:gh",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "fig",
        "kind": "completion",
        "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
        "license": "MIT"
      }
    ],
    "subcommand": [
      {
        "path": [
          "pr",
          "create"
        ],
        "label": "Create a pull request",
        "description": "Open a pull request for the current branch.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "title",
            "label": "Title",
            "type": "string",
            "option": [
              "--title",
              "-t"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "body",
            "label": "Body",
            "type": "string",
            "option": [
              "--body",
              "-b"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "base",
            "label": "Base branch",
            "type": "string",
            "option": [
              "--base",
              "-B"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "head",
            "label": "Head branch",
            "description": "Defaults to the current branch.",
            "type": "string",
            "option": [
              "--head",
              "-H"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "fill",
            "label": "Fill from commits",
            "description": "Skip prompts and use commit info for title and body.",
            "type": "boolean",
            "option": [
              "--fill",
              "-f"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "draft",
            "label": "Draft",
            "type": "boolean",
            "option": [
              "--draft",
              "-d"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "reviewer",
            "label": "Reviewers",
            "type": "string",
            "option": [
              "--reviewer",
              "-r"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "assignee",
            "label": "Assignees",
            "type": "string",
            "option": [
              "--assignee",
              "-a"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "web",
            "label": "Open in browser",
            "type": "boolean",
            "option": [
              "--web",
              "-w"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "fill",
            "label": "Quick PR from commits",
            "set": {
              "fill": [
                true
              ]
            },
            "fields": [
              "fill",
              "base",
              "draft",
              "reviewer"
            ],
            "required": []
          },
          {
            "id": "draft",
            "label": "Draft PR",
            "set": {
              "draft": [
                true
              ]
            },
            "fields": [
              "title",
              "body",
              "base",
              "draft"
            ],
            "required": [
              "title"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "title",
              "body",
              "base",
              "fill",
              "draft",
              "reviewer"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "head",
              "assignee",
              "web"
            ]
          }
        ]
      },
      {
        "path": [
          "pr",
          "list"
        ],
        "label": "List pull requests",
        "description": "List and filter pull requests in this repository.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "state",
            "label": "State",
            "type": "enum",
            "option": [
              "--state",
              "-s"
            ],
            "choices": [
              {
                "value": "open",
                "label": "Open"
              },
              {
                "value": "closed",
                "label": "Closed"
              },
              {
                "value": "merged",
                "label": "Merged"
              },
              {
                "value": "all",
                "label": "All"
              }
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "author_assignee",
            "label": "Assignee",
            "type": "string",
            "option": [
              "--assignee",
              "-a"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "base",
            "label": "Base branch",
            "type": "string",
            "option": [
              "--base",
              "-B"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "label",
            "label": "Label",
            "type": "string",
            "option": [
              "--label",
              "-l"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "limit",
            "label": "Limit",
            "type": "integer",
            "option": [
              "--limit",
              "-L"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "open-mine",
            "label": "My open PRs",
            "set": {
              "state": [
                "open"
              ],
              "author_assignee": [
                "@me"
              ]
            },
            "fields": [
              "state",
              "limit"
            ],
            "required": []
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "state",
              "author_assignee",
              "base",
              "label",
              "limit"
            ]
          }
        ]
      },
      {
        "path": [
          "issue",
          "create"
        ],
        "label": "Create an issue",
        "description": "Open a new issue.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "title",
            "label": "Title",
            "type": "string",
            "option": [
              "--title",
              "-t"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "body",
            "label": "Body",
            "type": "string",
            "option": [
              "--body",
              "-b"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "body_file",
            "label": "Body file",
            "type": "path",
            "option": [
              "--body-file",
              "-F"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "label",
            "label": "Labels",
            "type": "string",
            "option": [
              "--label",
              "-l"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "assignee",
            "label": "Assignees",
            "description": "Use @me to self-assign.",
            "type": "string",
            "option": [
              "--assignee",
              "-a"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "milestone",
            "label": "Milestone",
            "type": "string",
            "option": [
              "--milestone",
              "-m"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "repo",
            "label": "Repository",
            "description": "OWNER/REPO, when not in a checkout.",
            "type": "string",
            "option": [
              "--repo",
              "-R"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "web",
            "label": "Open in browser",
            "type": "boolean",
            "option": [
              "--web",
              "-w"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "quick",
            "label": "Quick issue",
            "fields": [
              "title",
              "body",
              "label",
              "assignee"
            ],
            "required": [
              "title"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "title",
              "body",
              "body_file",
              "label",
              "assignee"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "milestone",
              "repo",
              "web"
            ]
          }
        ]
      },
      {
        "path": [
          "issue",
          "list"
        ],
        "label": "List issues",
        "description": "List and filter issues in this repository.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "state",
            "label": "State",
            "type": "string",
            "option": [
              "--state",
              "-s"
            ],
            "suggestions": [
              {
                "value": "open",
                "label": "Open"
              },
              {
                "value": "closed",
                "label": "Closed"
              },
              {
                "value": "all",
                "label": "All"
              }
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "assignee",
            "label": "Assignee",
            "type": "string",
            "option": [
              "--assignee",
              "-a"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "author",
            "label": "Author",
            "type": "string",
            "option": [
              "--author",
              "-A"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "label",
            "label": "Labels",
            "type": "string",
            "option": [
              "--label",
              "-l"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "search",
            "label": "Search query",
            "type": "string",
            "option": [
              "--search",
              "-S"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "limit",
            "label": "Limit",
            "type": "integer",
            "option": [
              "--limit",
              "-L"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "repo",
            "label": "Repository",
            "description": "OWNER/REPO, when not in a checkout.",
            "type": "string",
            "option": [
              "--repo",
              "-R"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "mine",
            "label": "Issues assigned to me",
            "set": {
              "assignee": [
                "@me"
              ]
            },
            "fields": [
              "state",
              "label",
              "limit"
            ],
            "required": []
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "state",
              "assignee",
              "author",
              "label",
              "search",
              "limit"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "repo"
            ]
          }
        ]
      },
      {
        "path": [
          "repo",
          "clone"
        ],
        "label": "Clone a repository",
        "description": "Clone a GitHub repository locally.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/gh.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "repository",
            "label": "Repository",
            "description": "OWNER/REPO. The owner defaults to you if omitted.",
            "type": "string",
            "position": 0,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "directory",
            "label": "Directory",
            "type": "path",
            "position": 1,
            "path": {
              "kind": "directory",
              "role": "output",
              "must_exist": false
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "upstream",
            "label": "Upstream remote name",
            "description": "Remote name used when cloning a fork.",
            "type": "string",
            "option": [
              "--upstream-remote-name",
              "-u"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "clone",
            "label": "Clone",
            "fields": [
              "repository",
              "directory"
            ],
            "required": [
              "repository"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "repository",
              "directory"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "upstream"
            ]
          }
        ]
      }
    ]
  }
}
