Error: Could not find or load main class GroovyDemoClass
我正在使用类似于下面的build.xml文件
<project>
<target name="clean">
<delete dir="build"/>
</target>
<target name="compile">
<mkdir dir="build/classes"/>
<javac srcdir="src" destdir="build/classes"/>
</target>
<target name="jar">
<mkdir dir="build/jar"/>
<jar destfile="build/jar/GroovyDemoClass.jar" basedir="build/classes">
<manifest>
<attribute name="Main-Class" value="GroovyDemoClass"/>
</manifest>
</jar>
</target>
<target name="run">
<java jar="build/jar/GroovyDemoClass.jar" fork="true"/>
</target>
</project>
我的疑问是,ANT能否识别Java类文件之类的Groovy类文件