📜  更改 cwd 节点 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:48.230000             🧑  作者: Mango

代码示例1
console.log('Starting directory: ' + process.cwd());
try {
  process.chdir('/tmp');
  console.log('New directory: ' + process.cwd());
}
catch (err) {
  console.log('chdir: ' + err);
}