The stage object $Stage provides access to the properties of the current stage. This is also used as a child object of the Stages Collection under the Build Object e.g. $Build.Stages.First().Name$


NameDescriptionTypeUsage Example
AgentNameThe host name of the agent that the current stage is running on.String$Stage.AgentName$"ciagent01"
ElapsedThe time period since the current stage was started.TimeSpan$Stage.Elapsed$"00:10:01.7587427"
FinishedThe date/time when the current stage finished (if finished).DateTime$Stage.Finished$"9/11/2018 10:44:54"
HasWarnings
True if the current stage has warningsBoolean$Stage.HasWarnings$False
IsErrorTrue if the current stage has errorsBoolean$Stage.IsError$False
IsFailureTrue if the current stage has failuresBoolean$Stage.IsFailure$False
IsSpecialTrue if the current stage is a special stage created to run pre- or post-stage eventsBoolean$Stage.IsSpecial$False
IsSuccessfulTrue if the current stage is successfulBoolean$Stage.IsSuccessful$True
MetricsThe metrics associated with the current stage.Metrics$Stage.MetricsSee Metrics
NameThe name of the current stage as defined within the workflow editor.String$Stage.Name$"Test Stage"
OrderThe running order of the current stage.Integer$Stage.Order$2
StartedThe date/time when the current stage was started.DateTime$Stage.Started$"9/11/2018 10:34:53"



  • No labels