{
  "id": "gmt",
  "name": "GMT",
  "homepage": "https://www.generic-mapping-tools.org/",
  "executables": [
    "gmt"
  ],
  "dotfiles": {
    "paths": [
      "~/gmt.conf",
      "~/.gmt/gmt.conf",
      "~/.gmtdefaults4",
      "~/.gmt/.gmtdefaults4"
    ],
    "secret": []
  },
  "commands": {
    "format": 1,
    "label": "Inspect GMT installation",
    "description": "Print GMT installation details or a modern-mode script template. Running individual GMT modules (gmt plot, gmt grdimage ...) is not covered.",
    "quality": "ai-draft",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": false,
      "short_bundles": false
    },
    "source": [
      {
        "id": "man",
        "kind": "manual",
        "url": "https://manpages.debian.org/unstable/gmt/gmt.1.en.html",
        "revision": "2026-10-27",
        "evidence": "--help\nList and description of GMT modules.\n--new-script[=L]\nWrite a GMT modern mode script template to standard output. Optionally append the desired scripting language among bash, csh, or batch.\n--show-bindir\nShow directory of executables and exit.\n--show-citation\nShow the citation for the latest GMT publication.\n--show-cores\nShow number of available cores.\n--show-datadir\nShow data directory/ies and exit.\n--show-modules\nList modern module names on standard output and exit.\n--show-classic\nList classic module names on standard output and exit.\n--show-library\nShow the path of the shared GMT library.\n--show-plugindir\nShow plugin directory and exit.\n--show-sharedir\nShow share directory and exit.\n--show-userdir\nShow full path of user's ~/.gmt dir and exit.\n--version\nPrint version and exit.\n"
      }
    ],
    "field": [
      {
        "id": "version",
        "label": "Version",
        "type": "boolean",
        "option": [
          "--version"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "help",
        "label": "List modules",
        "type": "boolean",
        "option": [
          "--help"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_modules",
        "label": "Modern module names",
        "type": "boolean",
        "option": [
          "--show-modules"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_classic",
        "label": "Classic module names",
        "type": "boolean",
        "option": [
          "--show-classic"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_datadir",
        "label": "Data directory",
        "type": "boolean",
        "option": [
          "--show-datadir"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_userdir",
        "label": "User directory (~/.gmt)",
        "type": "boolean",
        "option": [
          "--show-userdir"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_sharedir",
        "label": "Share directory",
        "type": "boolean",
        "option": [
          "--show-sharedir"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "show_cores",
        "label": "Available cores",
        "type": "boolean",
        "option": [
          "--show-cores"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "new_script",
        "label": "Script template language",
        "description": "Write a modern-mode script template to standard output.",
        "type": "enum",
        "option": [
          "--new-script"
        ],
        "choices": [
          {
            "value": "bash",
            "label": "bash"
          },
          {
            "value": "csh",
            "label": "csh"
          },
          {
            "value": "batch",
            "label": "batch"
          }
        ],
        "sources": [
          "man"
        ]
      }
    ],
    "task": [
      {
        "id": "version",
        "label": "Show version",
        "set": {
          "version": [
            true
          ]
        },
        "lock": [
          "version"
        ],
        "fields": [
          "version"
        ],
        "required": []
      },
      {
        "id": "template",
        "label": "New script template",
        "fields": [
          "new_script"
        ],
        "required": [
          "new_script"
        ]
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "version",
          "help",
          "new_script"
        ]
      },
      {
        "id": "advanced",
        "label": "Show paths and modules",
        "fields": [
          "show_modules",
          "show_classic",
          "show_datadir",
          "show_userdir",
          "show_sharedir",
          "show_cores"
        ]
      }
    ]
  }
}
