PuTTY记录到相对路径?


1

我有一个便携式PuTTY安装,我从多台PC上运行。我想将会话记录到可执行文件所在的子文件夹中。我尝试了一些不同的选项,但是我收到了以下错误:

Error writing session log (raw mode) to file: logs/2016-09-30 132039.log
Error writing session log (raw mode) to file: /logs/2016-09-30 132053.log
Error writing session log (raw mode) to file: ./logs/2016-09-30 132102.log

这可能吗?我只是缺少一些明显的东西吗?

Answers:


2

使用反斜杠\

logs\2016-09-30 132039.log
.\logs\2016-09-30 132102.log

Windows文件路径使用反斜杠来分隔文件夹。Windows还禁止/文件名中的正斜杠,这会阻止创建文件。

注意:以反斜杠开头的中间选项将不起作用,因为文件名不能以反斜杠开头。

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.