{
  "id": "mailutils",
  "name": "GNU Mailutils",
  "homepage": "https://mailutils.org/",
  "description": "A suite of mail-related utilities",
  "executables": [
    "mail",
    "mailutils",
    "frm",
    "sieve"
  ],
  "dotfiles": {
    "paths": [
      "~/.mailrc"
    ],
    "secret": [],
    "secret_paths": [
      {
        "file": "~/.mailrc",
        "match": {
          "prefix": [
            "set smtp-auth-password",
            "set imap-password",
            "set pop-password",
            "set password"
          ]
        }
      }
    ]
  },
  "commands": {
    "format": 1,
    "label": "Send mail",
    "description": "Compose and send a message with GNU mail to one or more recipients; the body is read from standard input or typed. Mailbox reading, attachments' MIME options and configuration switches are left out.",
    "quality": "ai-draft",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "man",
        "kind": "manual",
        "url": "https://manpages.debian.org/unstable/mailutils/mail.1.en.html",
        "revision": "unstable 2026-10-27",
        "evidence": "mail.mailutils [OPTION...] [address...]\n  -A,\n    --attach=FILE\n  attach FILE\n-a, --append=HEADER: VALUE append given\n    header to the message being sent\n  -r,\n    --return-address=ADDRESS\n  use address as the return address when sending mail\n  -s,\n    --subject=SUBJ\n  send a message with the given SUBJECT\n  -n, --norc\n"
      }
    ],
    "field": [
      {
        "id": "to",
        "label": "Recipients",
        "type": "string",
        "position": 0,
        "multiple": true,
        "min": 1,
        "sources": [
          "man"
        ]
      },
      {
        "id": "subject",
        "label": "Subject",
        "type": "string",
        "option": [
          "--subject",
          "-s"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "attach",
        "label": "Attachments",
        "type": "path",
        "option": [
          "--attach",
          "-A"
        ],
        "path": {
          "kind": "file",
          "role": "input",
          "must_exist": true
        },
        "multiple": true,
        "sources": [
          "man"
        ]
      },
      {
        "id": "return_address",
        "label": "Return address",
        "type": "string",
        "option": [
          "--return-address",
          "-r"
        ],
        "sources": [
          "man"
        ]
      },
      {
        "id": "norc",
        "label": "Ignore ~/.mailrc",
        "type": "boolean",
        "option": [
          "--norc",
          "-n"
        ],
        "sources": [
          "man"
        ]
      }
    ],
    "task": [
      {
        "id": "send",
        "label": "Send a message",
        "fields": [
          "to",
          "subject",
          "attach"
        ],
        "required": [
          "to"
        ]
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "to",
          "subject",
          "attach"
        ]
      },
      {
        "id": "advanced",
        "label": "Advanced",
        "fields": [
          "return_address",
          "norc"
        ]
      }
    ]
  }
}
