execute

在 <command> 元素内使用 <execute> 元素来指定命令。元素的内容是要发送至服务器(由适配器使用)的一行或多行文本。不能在 <execute> 元素中使用点命令。<run> 元素调用 <command> 元素时,系统会将 <execute> 元素内容中的所有位置参数替换为所调用的 <run> 元素中指定的参数。<execute> 元素内容中的 $1 参数将由首个参数替换,$2 参数将由第二个参数替换,依此类推。

使用 condition="function" 属性控制 <execute> 元素中命令的执行。funtion 的值是一个表达式,其求值结果为 true 或 false。如果表达式求值结果为 true,那么系统执行命令;如果表达式求值结果为 false,那么不会执行命令。请参阅条件函数

<execute>
p4 changes -s submitted -t -i $2@$1,@now
</execute>

反馈