对于Inkscape,在Ant脚本中展开相对路径

Pau*_*her 3 ant build-automation filenames inkscape

我想编写一个Ant脚本来调用需要完整路径的外部实用程序(实际上是Inkscape).现在我有

<exec executable="${inkscape.path}">
    <arg value="--file=build_exe/splash.svg" />
    <arg value="--export-png=build_exe/splash.png" />
    <arg value="-C" />
</exec>
Run Code Online (Sandbox Code Playgroud)

在Windows上,Inkscape需要绝对路径.那么我怎么能哄Ant让我build_exe/filename成为一条绝对的道路呢?或者,或者,是否有针对Inkscape的解决方法(可能设置工作目录)?

Mih*_*der 5

用这个:

<property name="x" location="folder/file.txt" />
Run Code Online (Sandbox Code Playgroud)

${X}值将是文件相对于${basedir}值的绝对路径.