获取您的 自己的 Node 服务器
var path = require('path');
//Return the directries:
var directories = path.dirname('/Users/Refsnes/demo_path.js');
console.log(directories);

              

/Users/Refsnes