Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Launch debugger on your favorite port from your javascript code!

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 src
Octocat-spinner-32 .gitignore
Octocat-spinner-32 README.md
Octocat-spinner-32 custom-debug.js
Octocat-spinner-32 package.json
Octocat-spinner-32 test.js
Octocat-spinner-32 wscript
README.md

node-custom-debug

You have no need to fix your daemon's init scripts to enable debugging and profiling on the fly.

It's good to use with node-inspector to inspect many instances on the single server.

Installation

npm install -g custom-debug

Usage

See test.js:

var debug    = require("./custom-debug");
var profiler = require("v8-profiler");


var port = 5858;

console.log("Starting first time  : " + debug.start(port));
console.log("Starting second time : " + debug.start(port));

setInterval(function() {
    console.log("Another iteration..");
}, 1000);

To try that out:

  1. Run node test.js
  2. Run node-inspector
  3. Open your browser with the next link: http://localhost:8080/debug?port=58585

Authors

Something went wrong with that request. Please try again.