title: Get the node.js install path from code
body: <p>I'm trying to write a debugging framework for <a href="http://nodejs.org" rel="noreferrer">node.js</a> and am having a hard time figuring out how to get the full path to a core module file like <code>fs.js</code>.</p>
  
  <p>I've heard it's in the <code>/lib</code> folder of the node installation, but I'd need to get this from the code in a consistent way for a variety of install situations (including windows).</p>
  
  <p>I've tried taking a look at the <code>process</code> and <code>process.env</code> values for something like a node install path but can't see anything that immediately pops out at me.  </p>