/
index.cshtml
41 lines (34 loc) · 1.33 KB
/
index.cshtml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Order: 20
Description: Integration with Azure Pipelines
---
<h1 id="included-support">Out of the box support</h1>
<p>
The <a href="/api/Cake.Common.Build/BuildSystemAliases/AD2EF4E3">AzurePipelines alias</a>, which returns an
<a href="/api/Cake.Common.Build.AzurePipelines/IAzurePipelinesProvider">IAzurePipelinesProvider</a> instance can be used to interact with the Azure Pipelines environment.
</p>
<p>
The following example writes an error message if running on Azure Pipelines:
</p>
<pre><code class="language-csharp hljs">if (BuildSystem.AzurePipelines.IsRunningOnAzurePipelines)
{
BuildSystem.AzurePipelines.Commands.WriteError(
"This is a error message.");
}
else
{
Information("Not running on Azure Pipelines");
}</code></pre>
<div class="alert alert-info">
<p>
See <a href="/api/Cake.Common.Build.AzurePipelines/IAzurePipelinesProvider">IAzurePipelinesProvider</a> for details and available methods to interact with Azure Pipelines.
</p>
</div>
<h1 id="included-support">Available 3rd party extensions</h1>
@{
var keywords = new List<string> { "azurepipelines", "azuredevops", "tfs" };
var extensions =
Documents["Extensions"]
.Where(x =>
keywords.Any(y => x.String("Name").ToLowerInvariant().Contains(y)));
}
@Html.Partial("_ExtensionsList", extensions)