JavaFX Application Bundle Version Number
<p>I’m creating an installable bundle for a JavaFX 8 application using the Oracle tool that comes with the JDK.  On a Mac a <code>.dmg</code> file is created and on Linux a <code>.deb</code> file is used.  I call an Ant script from Gradle to create the bundle.  The problem that I have is that the version number contained in the bundle is always 1.0 and not the version that I specify.  The relevant part of the Ant script is as follows:</p>

<pre class="lang-xml prettyprint-override"><code>&lt;project name="VocabHunter Packaging" basedir=""
         xmlns:fx="javafx:com.sun.javafx.tools.ant"&gt;

    &lt;target name="jfxbundle" description="Build the application bundle"&gt;
        &lt;fx:deploy outdir="${basedir}/build"
                   nativeBundles="${packageType}"&gt;

            &lt;fx:application refId="VocabHunterId"
                            version="${version}"/&gt;

            &lt;fx:bundleArgument arg="mac.CFBundleVersion"
                               value="${version}"/&gt;
            ...
        &lt;/fx:deploy&gt;
        ...
    &lt;/target&gt;
    ...
&lt;/project&gt;
</code></pre>

<p>You can see the full script in context <a href="https://github.com/VocabHunter/VocabHunter/blob/1.0.8/package/bundle-ant.xml" rel="nofollow noreferrer">here</a>.</p>

<p>On a Mac, right-clicking the application icon and selecting “Get Info” shows 1.0 instead of the correct version number as you can see in the following screenshot:</p>

<p><a href="https://i.stack.imgur.com/r1jPQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/r1jPQ.png" alt="Mac Screenshot"></a></p>

<p>Similarly, on Linux the version number shows as 1.0 during the installation of the <code>.deb</code> file:</p>

<p><a href="https://i.stack.imgur.com/5YqUH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/5YqUH.png" alt="enter image description here"></a></p>

<p>Does anyone know how to fix Ant script so that the correct version appears?</p>

<p>I'm using Oracle JDK 1.8.0_66 on both the Mac and on LInux.</p>