You have a drawer full of USB cables. Half are junk that barely charge your phone. The other half transfer data at full speed. But which is which?

Android Studio solved this. Recent versions warn you when you connect a slow cable to your phone:

Android Studio Warning
developers.android.com

I wanted this for the command line. So I “built”1 usbi, a script to check your USB connections.

The script parses macOS’s system_profiler SPUSBDataType command, which produces a dense, hard-to-scan raw output:

raw output form macos command

With a little bit of scripting, the output becomes much cleaner:

usbi --speed output sample

When I connect my Pixel2:

usbi output with pixel phone attached

Quick notes on the vibe-coding experience

The first version was a bash script I cobbled together with AI. It worked, but was a mess to maintain. Because I let AI take the wheel, even minor tweaks like changing output colors were difficult.

Second time around, I decided to vibe-code again but asked AI to rewrite the entire thing in Go. I chose Go because I felt I could structure the code more legibly and tweaks would be easier to follow. Go also has the unique ability to compile a cross-platform binary, which I can run on any machine.

But perhaps the biggest reason is, it took me a grand total of 10 minutes to have AI rewrite the entire thing. I was punching through my email actively as Claude was chugging on the side.

Two years ago, I wouldn’t have bothered with the rewrite, let alone creating the script in the first place. The friction was too high. Now, small utility scripts like this are almost free to build.

That’s the real story. Not the script, but how AI changes the calculus of what’s worth our time.


  1. yes, vibe coded. Shamelessly, I might add. ↩︎

  2. I had Claude pull specs for the most common Pixel phones. I’ll do the same for iPhones if I ever switch back. ↩︎