• Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • ant-plugin
    • None

      It would be good if it would be possible to include the name of the build file in the function withAnt(...), I could not find any information in the documentation that this is possible. Because our build files are not called build.xml by default, so we would have to be able to specify a different name.

          [JENKINS-52730] Specify build file name

          Since withAnt only provides the Ant environment to ultimately shell out to ant, you can provide the buildfile with -buildfile on the ant command line:

           

          withAnt( installation: 'Ant' ) {
            bat 'ant <target> -buildfile mybuild.xml'
          }

           

           

          Stefan Drissen added a comment - Since withAnt only provides the Ant environment to ultimately shell out to ant, you can provide the buildfile with -buildfile on the ant command line:   withAnt( installation: 'Ant' ) { bat 'ant <target> -buildfile mybuild.xml' }    

            armfergom Armando Fernandez
            knotmich Michael Knoth
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: