BambooEnvironmentInfo.

Build Property

Summary

Gets Bamboo build information.

Syntax

public BambooBuildInfo Build { get; }

Examples

if (BuildSystem.Bamboo.IsRunningOnBamboo)
{
    Information(
        @"Build:
        Folder: {0}
        Number: {1}
        Build Key: {2}
        Result Key: {3}
        Results Url: {4}
        Build Timestamp: {5}
        Is Custom: {6}
        Revision Name: {7}",
        BuildSystem.Bamboo.Environment.Build.Folder,
        BuildSystem.Bamboo.Environment.Build.Number,
        BuildSystem.Bamboo.Environment.Build.BuildKey,
        BuildSystem.Bamboo.Environment.Build.ResultKey,
        BuildSystem.Bamboo.Environment.Build.ResultsUrl,
        BuildSystem.Bamboo.Environment.Build.BuildTimestamp,
        BuildSystem.Bamboo.Environment.Build.CustomBuild.IsCustomBuild,
        BuildSystem.Bamboo.Environment.Build.CustomBuild.RevisionName);
}
else
{
    Information("Not running on Bamboo");
}
if (Bamboo.IsRunningOnBamboo)
{
    Information(
        @"Build:
        Folder: {0}
        Number: {1}
        Build Key: {2}
        Result Key: {3}
        Results Url: {4}
        Build Timestamp: {5}
        Is Custom: {6}
        Revision Name: {7}",
        Bamboo.Environment.Build.Folder,
        Bamboo.Environment.Build.Number,
        Bamboo.Environment.Build.BuildKey,
        Bamboo.Environment.Build.ResultKey,
        Bamboo.Environment.Build.ResultsUrl,
        Bamboo.Environment.Build.BuildTimestamp,
        Bamboo.Environment.Build.CustomBuild.IsCustomBuild,
        Bamboo.Environment.Build.CustomBuild.RevisionName);
}
else
{
    Information("Not running on Bamboo");
}

Value

Type Description
BambooBuildInfo The Bamboo build information.