Knowledgebase:
Defining specific exit success codes
Posted by Yoni Davidson, Last modified by Yoni Davidson on 08 January 2018 03:56 PM

Note:

A valid DevTools Solution license is required to use XML Profiles when using IncrediBuild.

Sometimes there is a need to define specific exit codes since certain programs don't always return 0 as a success code and 1 as a failure code. 

For Visual Studio Builds

 Change the *.ib_profil.xml file to the following: 

 

<?xml version"1.0" encoding"utf-8" standalone"no" ?> 

<Profile FormatVersion"1"> 

  <Tools> 

    <Tool Filename="My TOOL" SuccessExitCodes="1" /> 

  </Tools> 

</Profile> 

The "My Tool" can be a custom step that is being executed and will return an exit code equal to 1 when everything is running correctly. The exit code will be equal to 0 if there are problems. 

Example for several sucess exit codes (for tools that have various success exit codes):

<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<Profile FormatVersion="1">
  <Tools>
       <Tool Filename="robocopy" SuccessExitCodes='0..8' />
  </Tools>
</Profile>

 As can be seen the "robocopy success exot codes are defined between the range of 0 to 8.

For XGE Builds

 Simply add the profile from above along with the /profile argument added to the end of your build command. 

(0 vote(s))
This article was helpful
This article was not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please enter the text you see in the image into the textbox below. This is required to prevent automated registrations and form submissions.

Help Desk Software by Kayako incredibuild.kayako.com