我试图重建如何在使用NPPExec的Notepad ++内在我的Windows机器上执行bash shell .sh
文件。 (我之前成功完成了这项工作,但是我的硬盘崩溃了,我不记得以前是怎么做的。)使用NppExec(和Cygwin)在Notepad ++中从Windows内部运行bash shell脚本
当它工作之前,我会运行NPPExec脚本,调用.sh
文件,向我展示了在Notepad ++中处理.sh文件的控制台输出,就好像它是在cygwin中处理的一样。
这是我想要去工作的例子sh文件:
message="Testing"
echo $message
该文件位于C盘根:。
失败尝试:
以下三种方法都不奏效:
- 执行:
C:\nppexec.sh
响应:
CreateProcess() failed with error code 193:
%1 is not a valid Win32 application.
- 执行:
npp_exec C:\nppexec.sh
响应:
message="Testing"
CreateProcess() failed with error code 2:
The system cannot find the file specified.
$message
添加
#! /bin/bash
到sh文件作为第一线只是导致当npp_exec运行的附加误差:NPP_EXEC: C:\nppexec.sh #! /bin/bash CreateProcess() failed with error code 2: The system cannot find the file specified.