Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9183261
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T18:45:33+00:00 2026-06-17T18:45:33+00:00

My project uses ANT build system. Currently, I am giving build via shell command

  • 0

My project uses ANT build system. Currently, I am giving build via shell command for my project. Say when I give “ant dev deploy” from cmd prompt(see below image for a successful build via cmd prompt) the build starts and in between it stops for confirmation from user. In the below image, I have highlighted the runtime value passed “dev”, which is passed as a confirmation variable, then the build continues based on the value passed.
This is how it should be and it was working correctly till now.

![Successful ANT build via cmd prompt][1]
Currently I am automating this build via hudson. I have given the value “ant dev deploy” in the targets of the Build properties in hudson. But, now I dont know how to configure to get the value “dev” in between the build progress. During my trial, I was getting error for that. Below, I have given the logs from Hudson.

Is there anyway I can pass the value on runtime.?

Sorry I am not able post images. Can clarify if any questions.

Oops! Your question couldn’t be submitted because:

•We’re sorry, but as a spam prevention mechanism, new users aren’t allowed to post images. Earn more than 10 reputation to post images

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T18:45:35+00:00Added an answer on June 17, 2026 at 6:45 pm

    You cannot pass a value to Hudson in the middle of the build. You need to supply that at the time of triggering the build. Hudson is not interactive, so anything in your current process that requires user prompting half way through needs to be redesigned.

    All your user prompting needs to be done through build parameters at the beginning of the build. In the job configuration, check mark This build is parameterized. If you want to restrict the possible values, a “Choice” parameter is best. Give it a name, for example CHOICE1, give it a list of possible choices. When the build is manually triggered, the user could choose one of the choices from a drop-down, and then start the build. Note that this will not work with builds that are automatically triggered.

    Next, you need to pass this value to your ANT script. In your Invoke Ant build step, click “Advanced” button, and under “Properties” you can pass variables to your ANT script:

    antScriptVar=$CHOICE1
    

    Above, $CHOICE1 is the reference to the Hudson build parameter, it will contain the value the user selected from the drop-down when starting the build. The antScriptVar is your variable in ANT script that will have this value. You can define the empty variable in ANT script with

    <property name="antScriptVar" value="" />
    

    When Hudson triggers the ANT script, it will populate this variable with the build variable. From then onwards, use it like you would any other variable in ANT

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to build my project using ANT. My project uses ActionbarSherlock, and Roboguice-Sherlock.
I'm working on a project that uses NetBeans to generate the ANT build files.
We have a project which uses the standalone Hibernate Tools Ant task to build
Our internal build system uses a shell script to setup the environment for building
I have got involved in a project. This project uses ant which is not
I am trying to install a project from github using phpunit. The project uses
When I try to build a project that uses Flex and where the Flex
I'm having some problems with my automated build system using ant and Cygwin. An
I'm trying to get Cobertura working for my project's Ant build, and all I
I have an Ant project that uses a bit of Coffee Script. I would

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.