I haven't maintained this in a while. You should probably use one of these things instead:
https://github.com/ChromeDevTools/awesome-chrome-devtools
-
Launch a browser with remote webkit inspector server enabled
open -a "Google Chrome Canary" --args --remote-debugging-port=9222 --user-data-dir="$TMPDIR/.chrome-user-data" about:blank
-
Find the first available debugger socket
DEBUGGER_SOCKET=$(curl -s "http://localhost:9222/json"|grep webSocketDebuggerUrl|cut -d'"' -f4| head -1)
