{
  "id": "erdtree",
  "name": "erdtree",
  "homepage": "https://github.com/solidiquis/erdtree",
  "description": "A modern, cross-platform, multi-threaded filesystem and disk-usage utility.",
  "executables": [
    "erd"
  ],
  "dotfiles": {
    "paths": [
      "[configHome]/erdtree/.erdtreerc",
      "[configHome]/.erdtreerc",
      "~/.config/erdtree/.erdtreerc",
      "~/.erdtreerc",
      "[configHome]/erdtree/.erdtree.toml",
      "[configHome]/.erdtree.toml",
      "~/.config/erdtree/.erdtree.toml",
      "~/.erdtree.toml"
    ],
    "secret": []
  },
  "commands": {
    "format": 1,
    "label": "Show directory tree",
    "description": "Print a directory tree with disk usage using erd. Config files, completions, thread tuning and column-width options are left out.",
    "quality": "ai-draft",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "help",
        "kind": "help",
        "url": "https://github.com/solidiquis/erdtree",
        "revision": "2026-10-27",
        "evidence": "Usage: erd [OPTIONS] [DIR]\n  [DIR]\n          Directory to traverse; defaults to current working directory\n  -d, --disk-usage <DISK_USAGE>\n          Possible values:\n          - logical:\n          - physical:\n          - line:\n          - word:\n          - block:\n  -H, --human\n          Print disk usage in human-readable format\n  -i, --no-ignore\n          Do not respect .gitignore files\n  -I, --icons\n          Display file icons\n  -l, --long\n          Show extended metadata and attributes\n  -L, --level <NUM>\n          Maximum depth to display\n  -p, --pattern <PATTERN>\n          Regular expression (or glob if '--glob' or '--iglob' is used) used to match files\n      --glob\n          Enables glob based searching\n  -P, --prune\n          Remove empty directories from output\n  -s, --sort <SORT>\n          Possible values:\n          - name:    - rname:   - size:    - rsize:   - access:  - raccess:\n          - create:  - rcreate: - mod:     - rmod:\n  -y, --layout <LAYOUT>\n          Possible values:\n          - regular:  - inverted: - flat:     - iflat:\n  -., --hidden\n          Show hidden files\n      --dirs-only\n          Only print directories\n      --suppress-size\n          Omit disk usage from output\n"
      }
    ],
    "field": [
      {
        "id": "dir",
        "label": "Directory",
        "description": "Defaults to the current directory.",
        "type": "path",
        "position": 0,
        "path": {
          "kind": "directory",
          "role": "input"
        },
        "sources": [
          "help"
        ]
      },
      {
        "id": "level",
        "label": "Max depth",
        "type": "integer",
        "option": [
          "--level",
          "-L"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "human",
        "label": "Human-readable sizes",
        "type": "boolean",
        "option": [
          "--human",
          "-H"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "disk_usage",
        "label": "Size metric",
        "type": "enum",
        "option": [
          "--disk-usage",
          "-d"
        ],
        "choices": [
          {
            "value": "logical",
            "label": "Logical bytes"
          },
          {
            "value": "physical",
            "label": "Physical bytes on disk"
          },
          {
            "value": "line",
            "label": "Line count"
          },
          {
            "value": "word",
            "label": "Word count"
          },
          {
            "value": "block",
            "label": "Blocks"
          }
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "sort",
        "label": "Sort order",
        "type": "enum",
        "option": [
          "--sort",
          "-s"
        ],
        "choices": [
          {
            "value": "name",
            "label": "Name"
          },
          {
            "value": "rname",
            "label": "Name (reversed)"
          },
          {
            "value": "size",
            "label": "Size, smallest first"
          },
          {
            "value": "rsize",
            "label": "Size, largest first"
          },
          {
            "value": "mod",
            "label": "Modified, newest first"
          },
          {
            "value": "rmod",
            "label": "Modified, oldest first"
          }
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "layout",
        "label": "Layout",
        "type": "enum",
        "option": [
          "--layout",
          "-y"
        ],
        "choices": [
          {
            "value": "regular",
            "label": "Regular (root at bottom)"
          },
          {
            "value": "inverted",
            "label": "Inverted (root at top)"
          },
          {
            "value": "flat",
            "label": "Flat paths"
          },
          {
            "value": "iflat",
            "label": "Inverted flat"
          }
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "hidden",
        "label": "Show hidden files",
        "type": "boolean",
        "option": [
          "--hidden",
          "-."
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "no_ignore",
        "label": "Ignore .gitignore",
        "description": "Do not respect .gitignore files.",
        "type": "boolean",
        "option": [
          "--no-ignore",
          "-i"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "long",
        "label": "Long view",
        "type": "boolean",
        "option": [
          "--long",
          "-l"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "icons",
        "label": "File icons",
        "type": "boolean",
        "option": [
          "--icons",
          "-I"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "dirs_only",
        "label": "Directories only",
        "type": "boolean",
        "option": [
          "--dirs-only"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "pattern",
        "label": "Match pattern",
        "description": "Regular expression used to match files.",
        "type": "string",
        "option": [
          "--pattern",
          "-p"
        ],
        "sources": [
          "help"
        ]
      },
      {
        "id": "prune",
        "label": "Prune empty directories",
        "type": "boolean",
        "option": [
          "--prune",
          "-P"
        ],
        "sources": [
          "help"
        ]
      }
    ],
    "task": [
      {
        "id": "usage",
        "label": "Disk usage overview",
        "fields": [
          "dir",
          "level",
          "human",
          "sort"
        ],
        "set": {
          "human": [
            true
          ]
        }
      },
      {
        "id": "find",
        "label": "Find files by pattern",
        "fields": [
          "dir",
          "pattern",
          "prune",
          "hidden"
        ],
        "required": [
          "pattern"
        ],
        "set": {
          "prune": [
            true
          ]
        }
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "dir",
          "level",
          "human",
          "disk_usage",
          "sort",
          "layout",
          "hidden"
        ]
      },
      {
        "id": "advanced",
        "label": "Advanced",
        "fields": [
          "no_ignore",
          "long",
          "icons",
          "dirs_only",
          "pattern",
          "prune"
        ]
      }
    ]
  }
}
