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

Tool design and implementation (macOS-only)

  • Tool parses system_profiler SPUSBHostDataType2 (or JSON variant) to infer link speed and flag likely “bad”/limiting cables.
  • Some commenters point out the source is in a dotfiles repo; others worry about trusting prebuilt binaries and prefer to inspect/compile themselves.
  • Debate over Go vs shell:
    • Critics say Go is overkill for a simple parser and adds compilation friction.
    • Supporters prefer Go’s readability/maintainability over complex bash and note cross-compiling is easy (though arguably irrelevant for a macOS‑specific tool).
  • Several note that a more robust design would use underlying macOS APIs instead of shelling out to a command that itself shells out.

Vibe coding and AI-generated utilities

  • Many see this as a good example of AI (“vibe coding”) lowering friction for small, personal tools that previously felt not worth the effort.
  • Multiple commenters share similar experiences: quickly generating one-off scripts for homelabs, data munging, media libraries, browser extensions, or internal business tooling.
  • Others push back:
    • Small scripts were already easy with Python/shell; AI doesn’t reduce “activation energy” for those comfortable coding.
    • Concern that “vibe coded” is used as a disclaimer to dodge responsibility for low-quality or poorly understood code.
    • One reviewer finds the usbi code fragile and unstructured (single large file, hard-coded strings, weak error handling), seeing it as hard to maintain.

USB‑C complexity and “bad cable” definition

  • Multiple stories of cables whose behavior changes with plug orientation, likely due to damaged or poorly wired pins and CC/e‑marker quirks; this surprises people who assumed full symmetry.
  • Discussion clarifies that while the connector is mechanically reversible, the electrical path and CC negotiation create an effective orientation, and partial failures are common.
  • Several emphasize that the script doesn’t actually “test” the cable: it only infers problems from negotiated speeds/power between host and device. It can’t explain many real‑world failures (e.g., alt‑mode displays, Thunderbolt vs USB‑only cables, protocol mismatches).

Platform support and alternatives

  • Non-macOS users are disappointed; suggestions include:
    • Linux: lsusb -v / lsusb -tv or using Cyme (cross‑platform USB viewer).
    • Windows: Microsoft’s USBView sample/tool.

Hardware testers, labeling, and usability

  • Several recommend dedicated USB‑C cable testers (various commercial and DIY boards) that check continuity, data/charge lines, and sometimes e‑markers.
  • Debate over labeling: some advocate printing capabilities on cables/ports; others note that specs, device compatibility, and dishonest manufacturers make labels only partially reliable.
  • Broader sentiment: USB‑C fulfilled the “one connector” dream but is confusing in practice, since identical‑looking cables/ports support wildly different capabilities.