java - 在 Windows 上构建 maven 期间无法执行 .sh 文件(CreateProcess 错误=193,%1 不是有效的 Win32 应用程序)
问题描述
我正在使用 Windows 10。当我在项目上使用 maven 构建时。在此过程中会执行.sh 文件。但是控制台会输出 CreateProcess error=193, %1 is not an valid Win32 application and failure。请问如何在windows上的maven构建期间运行.sh文件?我的pom文件如下。我挣扎了几天,寻找了很长时间。我使用 Maven 3.3.9
<plugin>
<artifactId>exec-maven-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId>
<executions>
<execution>
<id>testing</id>
<phase>generate-sources</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>${basedir}/src/hello-proto.sh</executable>
</configuration>
</execution>
</executions>
</plugin>
解决方案
推荐阅读
- powershell - PowerShell 以 csv 文件为源更新 csv 文件
- java - 在最近的 java 版本中使用 .war 传统项目时,非嵌入式 tomcat 中的 java 模块
- oracle - PLS-00103:在预期以下情况之一时遇到符号“文件结尾”:; - 不确定代码有什么问题
- jquery - JQuery中选择器内尖括号的含义
- r - 在文件名中添加相对丰富度
- amazon-redshift - 在 Redshift 上运行具有多个 CTE 的查询时可能出现内存错误
- python - 尝试使用 .bat 文件在指定浏览器中启动 jupyter lab
- python - 如何根据条件从字典中获取最大值
- python - 从熊猫日期范围中排除时间段
- python - Tesseract - 基数为 10 的 int() 的无效文字:'90.214363'