Checking the Status of a Task
When you run a target, the Ant Migration Tool outputs the request ID for each deploy or retrieve task included in the target. You can use the request ID to check the status of a deploy or retrieve task. This is particularly useful if a client is running for a long time and there is a network issue that breaks the connectivity between the Ant Migration Tool on your machine and Salesforce.
To check the status of a run target, use the following command:
ant -Dsf.asyncRequestId=requestID targetName
Use the requestID that was printed out when you ran the target. For example, if you run the deployZip target, you can run the following command to check the status of the retrieval:
ant -Dsf.asyncRequestId=04sx00000002aGuAAI deployZip
To track the status of deployments from within Salesforce, from Setup, enter Deployment in the Quick Find box, then select Deployment Status.