id = "mactop" name = "mactop" homepage = "https://github.com/metaspartan/mactop" description = "Apple Silicon Monitor Top written in Go Lang." executables = ["mactop"] platforms = ["macos"] [dotfiles] # The project's official README documents the XDG config/theme paths and the # legacy fallback when XDG_CONFIG_HOME is unset. It also documents state/log # output, but that runtime state is intentionally not captured here. # https://github.com/metaspartan/mactop/blob/main/README.md paths = [ "[configHome]/mactop/config.json", "[configHome]/mactop/theme.json", "~/.mactop/config.json", "~/.mactop/theme.json", ] secret = [] [commands] format = 1 label = "mactop" description = "Run the monitor TUI or print samples headlessly. Fan control (writes to SMC, needs root) is left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false } [[commands.source]] id = "readme" kind = "help" url = "https://github.com/metaspartan/mactop" evidence = """- `--headless`: Run in headless mode (no TUI, output to stdout). - `--format`: Output format for headless mode (json, yaml, xml, toon). Default is json. - `--count`: Number of samples to collect in headless mode (0 = infinite). - `--pretty`: Pretty print JSON output in headless mode. - `--interval` or `-i`: Set the update interval in milliseconds. Default is 1000. - `--foreground`: Set the UI foreground color. - `--bg` or `--background`: Set the UI background color. - `--prometheus` or `-p`: Set and enable the local Prometheus metrics server on the given port. - `--unit-network`: Network unit: auto, byte, kb, mb, gb (default: auto) - `--unit-disk`: Disk unit: auto, byte, kb, mb, gb (default: auto) - `--unit-temp`: Temperature unit: celsius, fahrenheit (default: celsius) - `--lang`: Language override (e.g., `en`, `es`, `ja`, `zh`).""" [[commands.field]] id = "headless" label = "Headless mode" description = "No TUI; print samples to stdout." type = "boolean" option = ["--headless"] sources = ["readme"] [[commands.field]] id = "format" label = "Output format" type = "enum" option = ["--format"] choices = [{ value = "json", label = "JSON" }, { value = "yaml", label = "YAML" }, { value = "xml", label = "XML" }, { value = "toon", label = "TOON" }] enabled_when = { field = "headless", op = "equals", value = true } sources = ["readme"] [[commands.field]] id = "count" label = "Sample count" description = "0 = infinite." type = "integer" option = ["--count"] enabled_when = { field = "headless", op = "equals", value = true } sources = ["readme"] [[commands.field]] id = "pretty" label = "Pretty print" type = "boolean" option = ["--pretty"] enabled_when = { field = "headless", op = "equals", value = true } sources = ["readme"] [[commands.field]] id = "interval" label = "Update interval (ms)" type = "integer" option = ["--interval", "-i"] sources = ["readme"] [[commands.field]] id = "foreground" label = "Foreground color" type = "string" option = ["--foreground"] suggestions = [{ value = "green", label = "Green" }, { value = "dracula", label = "Dracula" }, { value = "mocha", label = "Mocha" }] sources = ["readme"] [[commands.field]] id = "background" label = "Background color" type = "string" option = ["--bg", "--background"] suggestions = [{ value = "dracula-base", label = "Dracula" }, { value = "mocha-base", label = "Mocha" }] sources = ["readme"] [[commands.field]] id = "prometheus" label = "Prometheus port" type = "integer" option = ["--prometheus", "-p"] sources = ["readme"] [[commands.field]] id = "unit_network" label = "Network unit" type = "enum" option = ["--unit-network"] choices = [{ value = "auto", label = "Auto" }, { value = "byte", label = "Byte" }, { value = "kb", label = "KB" }, { value = "mb", label = "MB" }, { value = "gb", label = "GB" }] sources = ["readme"] [[commands.field]] id = "unit_disk" label = "Disk unit" type = "enum" option = ["--unit-disk"] choices = [{ value = "auto", label = "Auto" }, { value = "byte", label = "Byte" }, { value = "kb", label = "KB" }, { value = "mb", label = "MB" }, { value = "gb", label = "GB" }] sources = ["readme"] [[commands.field]] id = "unit_temp" label = "Temperature unit" type = "enum" option = ["--unit-temp"] choices = [{ value = "celsius", label = "Celsius" }, { value = "fahrenheit", label = "Fahrenheit" }] sources = ["readme"] [[commands.field]] id = "lang" label = "Language" type = "string" option = ["--lang"] suggestions = [{ value = "en", label = "English" }, { value = "ja", label = "Japanese" }, { value = "zh", label = "Chinese" }, { value = "es", label = "Spanish" }] sources = ["readme"] [[commands.task]] id = "monitor" label = "Interactive monitor" fields = ["interval", "foreground", "background", "unit_network", "unit_disk", "unit_temp", "lang"] required = [] [[commands.task]] id = "snapshot" label = "One JSON snapshot" set = { headless = [true], count = [1] } lock = ["headless"] fields = ["headless", "count", "format", "pretty"] required = [] [[commands.group]] id = "basic" label = "Basic" fields = ["headless", "format", "count", "pretty", "interval"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["foreground", "background", "prometheus", "unit_network", "unit_disk", "unit_temp", "lang"]