Custom Log Messages provide a way for processes executed by Continua CI to interact with the Continua CI build. This includes the ability to set the build number, set variables and send real time status information. This feature will be extended over time.

Message Format

@@continua[messageType parameter='value' parameter='value']

Note that the messageType field is not case sensitive. The parameter order is not defined, and parameter values must be quoted (with single quotes). NewLines, blackslashes, [ ] and single quotes must be escaped, e.g

@@continua[messageType name='test' value='This is a \nnew line and I am \'quoted\' by a\\b'] 

Message Types

message - Sends a message to to the build log. 

Parameters: value, status (debug, information, success, warning, error, fatal)


@@continua[message value='This will be logged' status='information']

startGroup - Starts a message group (tree node) in the build log.

Parameters: name


@@continua[startGroup name='Copying Files...']

 - Ends a message group (tree node) in the build log

Parameters: name


@@continua[endGroup name='Copying Files...']

- Sets a Continua CI configuration variable. Note that the variable name must be a Continua CI configuration variable. Optionally set the skipIfNotDefined attribute to 'true' to prevent the build failing if the variable has not been defined for the configuration.

Parameters: name, value, skipIfNotDefined


@@continua[setVariable name='allowupload' value='true']
@@continua[setVariable name='possiblyUnDefinedVariable' value='Hello world!' skipIfNotDefined='true']

setBuildVersion - Sets the current build's version string. 

Parameters:  value, verbose


@@continua[setBuildVersion value='1.2.3']

- Sets the current action's build status, which is shown on the build details page when a build is running.

Parameters: name, verbose


@@continua[setBuildStatus value='Copying Files...']

pinBuild - Pins the current build, so that it is listed at the top of the build history and excluded from build cleanup. Optionally provide a comment to be associated with the pin and set the appendComment attribute to 'true' to append it to any existing comment.

Parameters: comment, appendComment, verbose


@@continua[pinBuild comment='Keep this awesome build' appendComment='true']

unpinBuild - Removes any pins from the current build.

Parameters: verbose

Example : 


tagBuild - Adds the supplied tag to the current build. Optionally set the replaceExisting attribute to 'true' to remove any existing tags first.

Parameters: tag, replaceExisting, verbose


@@continua[tagBuild tag='deployed' replaceExisting='true']

removeBuildTag - Remove a tag or all tags from current build. Either provide the name of the tag to remove or set the removeAll attribute to 'true' to remove all existing tags.

Parameters: tag, removeAll, verbose


@@continua[removeBuildTag tag='deployed']

@@continua[removeBuildTag removeAll='true']

addBuildComment- Adds the supplied comment to the current build. Optionally set the replaceExisting attribute to 'true' to remove any existing comments first.

Parameters: comment, replaceExisting, verbose


@@continua[addBuildComment comment='This build was deployed to staging' replaceExisting='true']

importUnitTestResults - Imports unit tests and totals from unit test result files and registers them with the server. 


  • type: One of junit, mstest, nunit or xunit. Identifies the type of unit test runner that created the results file. This is required.
  • filePatterns: One or more paths to result files separated by the pipe character. Each path may contain ANT pattern wildcards. This is required.
  • failIfTestFails: When true, the stage fails if any unit test fails. Defaults to true.
  • failIfTestErrors: When true, the stage fails if any unit test errors. Defaults to true.
  • quiet: When true, any non-error log messages are suppressed. Defaults to false.


@@continua[importUnitTestResults type='nunit' filePatterns='C:\pathto\tests\**.xml|C:\another\pathto\tests\**.xml' failIfTestFails='false' failIfTestErrors='false' quiet='false' verbose='false']

Common parameters

If the verbose parameter is set to true for any of the message types above, additional text describing the action will be written to the build log.

Example : 

@@continua[setBuildVersion value='1.2.3' verbose='true']

  • No labels