{
  "id": "topgrade",
  "name": "Topgrade",
  "homepage": "https://github.com/topgrade-rs/topgrade",
  "executables": [
    "topgrade"
  ],
  "dotfiles": {
    "paths": [
      "[configHome]/topgrade.toml",
      "[configHome]/topgrade/topgrade.toml",
      "[configHome]/topgrade.d/"
    ],
    "secret": [],
    "side_effect": false
  },
  "commands": {
    "format": 1,
    "label": "Upgrade everything",
    "description": "Run Topgrade's upgrade steps with a dry run, step selection and retry behaviour. Custom commands, environment variables, notifications and logging options are left out.",
    "quality": "ai-draft",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": false,
      "short_attached": true,
      "short_bundles": true
    },
    "source": [
      {
        "id": "cli",
        "kind": "manual",
        "url": "https://raw.githubusercontent.com/topgrade-rs/topgrade/HEAD/src/config.rs",
        "revision": "2026-10-27",
        "evidence": "-n, --dry-run                Print what would be done\n--disable <STEP>...         Do not perform upgrades for the given steps\n--only <STEP>...            Perform only the specified steps\n-y, --yes [<STEP>...]       Say yes to package manager's prompt\n-v, --verbose               Output debug logs. Alias for `--log-filter debug`.\n-k, --keep                  Prompt for a key before exiting\n--no-ask-retry              Do not ask what to do after a step fails\n--auto-retry <COUNT>        Automatically retry failed steps up to COUNT times\n--config <PATH>             Alternative configuration file\n--show-skipped              Show the reason for skipped steps\n--no-self-update            Don't update Topgrade\n--sudoloop                  Periodically run `sudo -v` to avoid password re-prompts during updates\n(Help text transcribed from the clap #[arg(...)] doc comments in src/config.rs.)\n"
      }
    ],
    "field": [
      {
        "id": "dry_run",
        "label": "Dry run",
        "description": "Print what would be done without upgrading anything.",
        "type": "boolean",
        "option": [
          "--dry-run",
          "-n"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "only",
        "label": "Only these steps",
        "description": "Step names such as brew, cargo or system. Only these steps run.",
        "type": "string",
        "option": [
          "--only"
        ],
        "multiple": true,
        "sources": [
          "cli"
        ]
      },
      {
        "id": "disable",
        "label": "Skip these steps",
        "description": "Step names to leave out of the run.",
        "type": "string",
        "option": [
          "--disable"
        ],
        "multiple": true,
        "sources": [
          "cli"
        ]
      },
      {
        "id": "yes",
        "label": "Answer yes to prompts",
        "description": "Say yes to the package managers' prompts.",
        "type": "boolean",
        "option": [
          "--yes",
          "-y"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "no_self_update",
        "label": "Skip Topgrade self-update",
        "type": "boolean",
        "option": [
          "--no-self-update"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "no_ask_retry",
        "label": "Do not ask to retry failures",
        "type": "boolean",
        "option": [
          "--no-ask-retry"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "auto_retry",
        "label": "Automatic retries",
        "description": "Retry failed steps up to this many times.",
        "type": "integer",
        "option": [
          "--auto-retry"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "config",
        "label": "Config file",
        "type": "path",
        "option": [
          "--config"
        ],
        "path": {
          "kind": "file",
          "role": "input"
        },
        "sources": [
          "cli"
        ]
      },
      {
        "id": "show_skipped",
        "label": "Show skipped reasons",
        "type": "boolean",
        "option": [
          "--show-skipped"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "sudoloop",
        "label": "Keep sudo alive",
        "description": "Periodically run sudo -v to avoid password re-prompts.",
        "type": "boolean",
        "option": [
          "--sudoloop"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "keep",
        "label": "Wait for a key at the end",
        "type": "boolean",
        "option": [
          "--keep",
          "-k"
        ],
        "sources": [
          "cli"
        ]
      },
      {
        "id": "verbose",
        "label": "Verbose",
        "type": "boolean",
        "option": [
          "--verbose",
          "-v"
        ],
        "sources": [
          "cli"
        ]
      }
    ],
    "task": [
      {
        "id": "preview",
        "label": "Preview upgrades",
        "fields": [
          "dry_run",
          "only",
          "disable",
          "show_skipped"
        ],
        "set": {
          "dry_run": [
            true
          ]
        }
      },
      {
        "id": "unattended",
        "label": "Unattended upgrade",
        "fields": [
          "yes",
          "no_ask_retry",
          "auto_retry",
          "disable",
          "only"
        ],
        "set": {
          "yes": [
            true
          ]
        }
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "dry_run",
          "only",
          "disable",
          "yes",
          "no_self_update",
          "verbose"
        ]
      },
      {
        "id": "advanced",
        "label": "Advanced",
        "fields": [
          "no_ask_retry",
          "auto_retry",
          "config",
          "show_skipped",
          "sudoloop",
          "keep"
        ]
      }
    ]
  }
}
