exec maven插件无法正确使用参数

exec maven插件无法正确使用参数,maven,openldap,exec-maven-plugin,Maven,Openldap,Exec Maven Plugin,我尝试用一些参数执行一个shell脚本(实际上是OpenLDAP的ldapmodify)。我在pom.xml中就是这样做的: 在Maven概要文件中,我定义了一些值 <profile> <id>Linux-OpenLDAP</id> <activation> <os> <family>Unix</family>

我尝试用一些参数执行一个shell脚本(实际上是OpenLDAP的ldapmodify)。我在pom.xml中就是这样做的:

在Maven概要文件中,我定义了一些值

<profile>
    <id>Linux-OpenLDAP</id>
         <activation>
             <os>
                  <family>Unix</family>
             </os>
         </activation>
    <properties>
        <OpenLdap.ClientTools.home></OpenLdap.ClientTools.home>
        <executable>/usr/local/bin/ldapmodify</executable>
        <argument>-a -x -h localhost -p 389 -D "cn=manager,dc=my-domain,dc=com" -f ${test-users.idif.path} -w secret</argument>
    </properties>
</profile>

如果我直接在commnad行中运行
/usr/local/bin/ldapmodify-a-x-hlocalhost-p389-D“cn=manager,dc=ibm,dc=com”-f/home/entity-matching/entity-matching bootstrap/src/test/resources/test\u users.ldif-w secret
,它就会成功。那么,为什么在mvn安装期间该选项无效呢?

问题在于您将
嵌入了
部分。只需记住
部分:

<configuration>
  <executable>${executable}</executable>
  <commandlineArgs>${argument}</commandlineArgs>
</configuration>

${executable}
${argument}

问题在于您将
嵌入了
部分。只需记住
部分:

<configuration>
  <executable>${executable}</executable>
  <commandlineArgs>${argument}</commandlineArgs>
</configuration>

${executable}
${argument}

天哪……我太粗心了。谢谢。天哪……我太粗心了。谢谢
<configuration>
  <executable>${executable}</executable>
  <commandlineArgs>${argument}</commandlineArgs>
</configuration>