Building on the existing answers here, you could define this in your REPL:
__dirname = path.resolve(path.dirname(''));
Or:
__dirname = path.resolve();
Or @Jthorpe's alternatives:
__dirname = process.cwd();
__dirname = fs.realpathSync('.');
__dirname = process.env.PWD