aboutsummaryrefslogtreecommitdiff
path: root/bin/usbInf
diff options
context:
space:
mode:
Diffstat (limited to 'bin/usbInf')
-rwxr-xr-xbin/usbInf7
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/usbInf b/bin/usbInf
new file mode 100755
index 0000000..14e4bf0
--- /dev/null
+++ b/bin/usbInf
@@ -0,0 +1,7 @@
+system_profiler SPUSBDataType \
+ | awk '
+ /Product ID:/{p=$3}
+ /Vendor ID:/{v=$3}
+ /Manufacturer:/{sub(/.*: /,""); m=$0}
+ /Location ID:/{sub(/.*: /,""); printf("%s:%s %s (%s)\n", v, p, $0, m);}
+ '