Live data from Hacker News

A macOS terminal command that tells you if your USB-C cable is bad

kau.sh

1–10 of 197 posts

Re: A macOS terminal command that tells you if your USB-C cable is bad

#2
> The script parses macOS’s system_profiler SPUSBHostDataType2 command, which produces a dense, hard-to-scan raw output

I couldn’t find source (the link in the article points to a GitHub repo of a user’s home directory. I hope for them it doesn’t contain secrets), but on my system, system_profiler -json produces json output. From that text, it doesn’t seem they used that.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#3
post #2

> The script parses macOS’s system_profiler SPUSBHostDataType2 command, which produces a dense, hard-to-scan raw output I couldn’t find source (the link in the article points to a GitHub repo of a user’s home directory. I hope for them it doesn’t contain secrets), but on my system, system_profiler -json produces json output. From that text, it doesn’t seem they used that.

internally uses the same root command btw. in fact this recently changed for Tahoe (as the article mentions).

started out as a shell script but switched to a go binary (which is what is linked).

Re: A macOS terminal command that tells you if your USB-C cable is bad

#4
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.

This aligns with the hypothesis that we should see and lots lots of "personalized" or single purpose software if vibe coding works. This particular project is one example. Are there a ton more out there?

Re: A macOS terminal command that tells you if your USB-C cable is bad

#5
It's more complicated than "this cable is good/bad". I had a suspicion about one of my cables for months, but just last week I confirmed it with a device that shows the volts/amps/watts/total kwh passing through it: I have a USB-C cable with orientation. Plugged in one way it transfers about 5x more power than the other way, and in the lower orientation it's low enough for the earbud case I use it with to not charge.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#6

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. This aligns with the hypothesis that we should see and lots lots of "personalized" or single purpose software if vibe coding works. This particular project is one example. Are there a ton more out there?

I've used chatgpt to make custom userscripts for neopets but I've never published them.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#7

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. This aligns with the hypothesis that we should see and lots lots of "personalized" or single purpose software if vibe coding works. This particular project is one example. Are there a ton more out there?

Simon Willison's list has a few: https://tools.simonwillison.net/

Re: A macOS terminal command that tells you if your USB-C cable is bad

#8

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. This aligns with the hypothesis that we should see and lots lots of "personalized" or single purpose software if vibe coding works. This particular project is one example. Are there a ton more out there?

I have a bunch at work, yes. Can't publish them.

Just an hour ago I "made" one in 2 minutes to iterate through some files, extract metadata, and convert to CSV.

I'm convinced that hypothesis is true. The activation energy (with a subscription to one of the big 3, in the current pre-enshittification phase) is approximately 0.

Edit: I also wouldn't even want to publish these one-off, AI-generated scripts, because for one they're for specific niches, and for two they're AI generated so, even though they fulfilled their purpose, I don't really stand behind them.

Post reply on HN