Setup Ant to use JDK different from one specified in JAVA_HOME

后端 未结 1 1091
心在旅途
心在旅途 2021-01-23 21:54

So for reason of running many projects, I don\'t want to change JAVA_HOME variable (1.6) but I would like ant to run and use 1.5 JDK.

I have manage to do this from Ecli

1条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-23 22:49

    You can write your own script, called ant2 or similar, to execute ant from the JDK that you want and add it into the PATH.

    0 讨论(0)
提交回复
热议问题