Browse files

continue 'the easy way' when no gui is attached. issue #1

  • Loading branch information...
1 parent 3d7be78 commit a37a27f52edafd2d72202f645cb9c1ea4dba3499 @dannycoates dannycoates committed Jul 21, 2010
Showing with 11 additions and 3 deletions.
  1. +9 −1 bin/inspector.js
  2. +2 −2 readme.md
View
10 bin/inspector.js
@@ -34,7 +34,15 @@ function parseBody() {
current.body = buffer.slice(0, current.contentLength);
buffer = buffer.slice(current.contentLength);
if (current.body.length > 0 && wsServer) {
- wsServer.broadcast(current.body);
+ if (wsServer.manager.length === 0) {
+ var msg = JSON.parse(current.body);
+ if (msg.type === 'event' && msg.event === 'break') {
+ request('{"seq":0,"type":"request","command":"continue"}');
+ }
+ }
+ else {
+ wsServer.broadcast(current.body);
+ }
}
current = false;
parse();
View
4 readme.md
@@ -24,7 +24,7 @@ As an example lets debug test/hello.js, from the root project directory (node-in
1. start the inspector like this:
> node bin/inspector.js --start=test/hello.js
-2. open http://localhost:8080 in your favorite WebKit based browser
+2. open http://127.0.0.1:8080 in your favorite WebKit based browser
3. you should now see the javascript source from nodeJS
@@ -41,7 +41,7 @@ external node process.
2. start the inspector:
> node bin/inspector.js --debug-port=7878 --agent-port=8000
-3. open http://localhost:8000
+3. open http://127.0.0.1:8000
## Options

0 comments on commit a37a27f

Please sign in to comment.