{"id":13522237,"url":"https://github.com/vladkens/macmon","last_synced_at":"2025-05-14T23:07:50.560Z","repository":{"id":244637466,"uuid":"815813101","full_name":"vladkens/macmon","owner":"vladkens","description":"🦀⚙️ Sudoless performance monitoring for Apple Silicon processors. CPU / GPU / RAM usage, power consumption \u0026 temperature 🌡️","archived":false,"fork":false,"pushed_at":"2025-02-26T00:56:27.000Z","size":384,"stargazers_count":673,"open_issues_count":8,"forks_count":21,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-04-15T05:32:05.114Z","etag":null,"topics":["apple","apple-silicon","arm64","asitop","cli","cpu","cpu-monitoring","cpu-usage","gpu","gpu-monitoring","gpu-usage","m1","macos","monitoring","powermetrics","ratatui","rust","smc","terminal","tui"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vladkens.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"vladkens","buy_me_a_coffee":"vladkens"}},"created_at":"2024-06-16T08:34:34.000Z","updated_at":"2025-04-15T04:02:23.000Z","dependencies_parsed_at":"2024-06-27T03:25:14.103Z","dependency_job_id":"62e94916-b683-483f-bbc9-c9b175346fc5","html_url":"https://github.com/vladkens/macmon","commit_stats":null,"previous_names":["vladkens/macmon"],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vladkens%2Fmacmon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vladkens%2Fmacmon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vladkens%2Fmacmon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vladkens%2Fmacmon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vladkens","download_url":"https://codeload.github.com/vladkens/macmon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254243362,"owners_count":22038046,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["apple","apple-silicon","arm64","asitop","cli","cpu","cpu-monitoring","cpu-usage","gpu","gpu-monitoring","gpu-usage","m1","macos","monitoring","powermetrics","ratatui","rust","smc","terminal","tui"],"created_at":"2024-08-01T06:00:44.379Z","updated_at":"2025-05-14T23:07:45.527Z","avatar_url":"https://github.com/vladkens.png","language":"Rust","readme":"# `macmon` – Mac Monitor\n\n\u003cdiv align=\"center\"\u003e\n\nSudoless performance monitoring CLI tool for Apple Silicon processors.\n\n[\u003cimg src=\"https://badges.ws/github/assets-dl/vladkens/macmon\" /\u003e](https://github.com/vladkens/macmon/releases)\n[\u003cimg src=\"https://badges.ws/github/release/vladkens/macmon\" /\u003e](https://github.com/vladkens/macmon/releases)\n[\u003cimg src=\"https://badges.ws/github/license/vladkens/macmon\" /\u003e](https://github.com/vladkens/macmon/blob/main/LICENSE)\n[\u003cimg src=\"https://badges.ws/badge/-/buy%20me%20a%20coffee/ff813f?icon=buymeacoffee\u0026label\" alt=\"donate\" /\u003e](https://buymeacoffee.com/vladkens)\n\n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"https://github.com/vladkens/macmon/blob/assets/macmon.png?raw=true\" alt=\"preview\" /\u003e\n\u003c/div\u003e\n\n## Motivation\n\nApple Silicon processors don't provide an easy way to see live power consumption. I was interested in this information while testing local LLM models. `asitop` is a nice and simple TUI to quickly see current metrics, but it reads data from `powermetrics` and requires root privileges. `macmon` uses a private macOS API to gather metrics (essentially the same as `powermetrics`) but runs without sudo. 🎉\n\n## 🌟 Features\n\n- 🚫 Works without sudo\n- ⚡ Real-time CPU / GPU / ANE power usage\n- 📊 CPU utilization per cluster\n- 💾 RAM / Swap usage\n- 📈 Historical charts + avg / max values\n- 🌡️ Average CPU / GPU temperature\n- 🎨 Switchable colors (6 variants)\n- 🪟 Can be rendered in a small window\n- 🦀 Written in Rust\n\n## 🍺 Install via Homebrew\n\nYou can install [`macmon`](https://formulae.brew.sh/formula/macmon) using [brew](https://brew.sh/):\n\n```sh\n$ brew install macmon\n```\n\n## 🖥️ Install via MacPorts\n\nYou can also install [`macmon`](https://ports.macports.org/port/macmon/) using [MacPorts](https://macports.org/):\n\n```sh\n$ sudo port install macmon\n```\n\n## 📦 Install from source\n\n1. Install [Rust toolchain](https://www.rust-lang.org/tools/install)\n\n2. Clone the repo:\n\n```sh\ngit clone https://github.com/vladkens/macmon.git \u0026\u0026 cd macmon\n```\n\n3. Build and run:\n\n```sh\ncargo run -r\n```\n\n4. (Optionally) Binary can be moved to bin folder:\n\n```sh\nsudo cp target/release/macmon /usr/local/bin\n```\n\n## 🚀 Usage\n\n```sh\nUsage: macmon [OPTIONS] [COMMAND]\n\nCommands:\n  pipe   Output metrics in JSON format\n  debug  Print debug information\n  help   Print this message or the help of the given subcommand(s)\n\nOptions:\n  -i, --interval \u003cINTERVAL\u003e  Update interval in milliseconds [default: 1000]\n  -h, --help                 Print help\n  -V, --version              Print version\n\nControls:\n  c - change color\n  v - switch charts view: gauge / sparkline\n  q - quit\n```\n\n## 🚰 Piping\n\nYou can use the pipe subcommand to output metrics in JSON format, which is suitable for piping into other tools or scripts. For example:\n\n```sh\nmacmon pipe | jq\n```\n\nThis command runs `macmon` in \"pipe\" mode and navigate output to `jq` for pretty-printing.\n\nYou can also specify the number of samples to run using `-s` or `--samples` parameter (default: `0`, which runs indefinitely), and set update interval in milliseconds using the `-i` or `--interval` parameter (default: `1000` ms). For example:\n\n```sh\nmacmon pipe -s 10 -i 500 | jq\n```\n\nThis will collect 10 samples with an update interval of 500 milliseconds.\n\n### Output\n\n```jsonc\n{\n  \"timestamp\": \"2025-02-24T20:38:15.427569+00:00\",\n  \"temp\": {\n    \"cpu_temp_avg\": 43.73614,         // Celsius\n    \"gpu_temp_avg\": 36.95167          // Celsius\n  },\n  \"memory\": {\n    \"ram_total\": 25769803776,         // Bytes\n    \"ram_usage\": 20985479168,         // Bytes\n    \"swap_total\": 4294967296,         // Bytes\n    \"swap_usage\": 2602434560          // Bytes\n  },\n  \"ecpu_usage\": [1181, 0.082656614],  // (Frequency MHz, Usage %)\n  \"pcpu_usage\": [1974, 0.015181795],  // (Frequency MHz, Usage %)\n  \"gpu_usage\": [461, 0.021497859],    // (Frequency MHz, Usage %)\n  \"cpu_power\": 0.20486385,            // Watts\n  \"gpu_power\": 0.017451683,           // Watts\n  \"ane_power\": 0.0,                   // Watts\n  \"all_power\": 0.22231553,            // Watts\n  \"sys_power\": 5.876533,              // Watts\n  \"ram_power\": 0.11635789,            // Watts\n  \"gpu_ram_power\": 0.0009615385       // Watts (not sure what it means)\n}\n```\n\n## 🤝 Contributing\nWe love contributions! Whether you have ideas, suggestions, or bug reports, feel free to open an issue or submit a pull request. Your input is essential in helping us improve `macmon` 💪\n\n## 📝 License\n`macmon` is distributed under the MIT License. For more details, check out the LICENSE.\n\n## 🔍 See also\n- [tlkh/asitop](https://github.com/tlkh/asitop) – Original tool. Python, requires sudo.\n- [dehydratedpotato/socpowerbud](https://github.com/dehydratedpotato/socpowerbud) – ObjectiveC, sudoless, no TUI.\n- [op06072/NeoAsitop](https://github.com/op06072/NeoAsitop) – Swift, sudoless.\n- [graelo/pumas](https://github.com/graelo/pumas) – Rust, requires sudo.\n- [context-labs/mactop](https://github.com/context-labs/mactop) – Go, requires sudo.\n\n---\n\n*PS: One More Thing... Remember, monitoring your Mac's performance with `macmon` is like having a personal trainer for your processor — keeping those cores in shape! 💪*\n","funding_links":["https://github.com/sponsors/vladkens","https://buymeacoffee.com/vladkens"],"categories":["System Monitor","HarmonyOS","Rust","\u003ca name=\"monitor\"\u003e\u003c/a\u003eSystem monitoring","Table of Contents","💻 Apps"],"sub_categories":["Windows Manager","👨‍💻 System Administration"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvladkens%2Fmacmon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvladkens%2Fmacmon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvladkens%2Fmacmon/lists"}