Cheetah banner

Cheetah

6 devlogs
12h 1m 57s

Cheetah is a native macOS app written in Swift, designed to be a knock-off RunCat. The app displays an animal/object in your menu bar which moves and is animated faster the more CPU you are using.

This project uses AI

GH Copilot code completions
Basic help from Ai to extract RunCat assets and help with some optimisation

Demo Repository

Loading README...

hi7

Shipped this project!

I built Cheetah, a menu bar app for macOS (so you need to be rich to use it) that lets you visualise your CPU usage. The hardest part was, by far, optimising the app to have low CPU

hi7

I made this ship ready by making a README and modifying a website I had already made to suit the app (maybe because I didn’t feel like making yet another website lol)
I also added the Github Release in the form of a compressed DMG (as for some reason normal DMG upload wasn’t working…)

Attachment
0
hi7

I added an onboarding flow for easier setup. I also optimised the app… again. This was the worst part, as I thought I was done but no. The app loves hogging CPU. Although the fix was easy, just not making it monitor as much in the background and dynamically scaling FPS and the app is back to sub‑1 percent at idle.

Attachment
Attachment
0
hi7

I improved the settings menu a lot. Before, it was just a simple runner selector, but now I’ve stylized it, made it easier to understand, and added many more options. The user can change the dashboard tiles, change the runner (plus a search bar), launch at login, randomly change the runner, and much more. I’m so happy with this, as it makes the UI and UX much better. I also added the app icon (the layers with Canva, put together in Icon Composer).

Attachment
Attachment
Attachment
Attachment
0
hi7

I designed and made the popup for when you click on the menu bar icon. it shows your CPU load, memory usage, breakdown of your CPU cores, uptime, a graph of your usage history, and a a lsit of the top 5 processes. It also has a quit button and a settings button. Overall I’m really happy with how this looks.

Attachment
0
hi7

I optimised the app WAYYY more. This part was more difficult than before because the bulk of optimisation was done; it was just the final things that would bring it down to ~1%. Most of this time was spent staring at activity monitor until I found something wrong and then fix the bug. But now, the result is less than 0.9% CPU usage and less than 50MB memory, which are both equal or better than RunCat!!!

Attachment
Attachment
0
hi7

I wrote the code for the app to create the MVP. To make this, I had to:

  1. First extract the assets of the RunCat avatars using the .car library.
  2. Write Swift code that selects the Puppy avatar (because that’s my favorite) and animates it faster the higher the CPU usage.
  3. I looked at Activity Monitor and, oh god… my app was using 20 percent CPU. 20 percent!!!!! I urgently quit the app and immediately capped the FPS and applied some basic optimisations, which brought it down to about 7 percent.
  4. I still wasn’t happy with that, so I asked ChatGPT for help and then made the following improvement: the app keeps each runner animation in a small cache, which avoids repeated frame reloads, and it only updates the menu icon when the image actually changes.

All together this brings CPU usage down to around 3 percent, which is good but I’m not 100 percent happy with it so I will keep optimising!!

Attachment
Attachment
0