current file path nodejs code example Example 1: how to get cwd nodejs process.cwd() Example 2: node get path of current file module.filename