spectre.console/docs/src/Extensions/BootstrapperExtensions.cs
Khalid Abuhakmeh 672faa131f Update Docs Readme
Added some more context to the docs readme for
folks looking to contribute. Also added the license
so its clear what the license of the docs site is. As
a small tweak I removed a duplicate string value and
use the Constant.
2020-10-01 20:51:32 +02:00

28 lines
881 B
C#

using Statiq.App;
using Statiq.Common;
using System.Collections.Generic;
using System.Linq;
namespace Docs
{
public static class BootstrapperExtensions
{
public static Bootstrapper ConfigureSite(this Bootstrapper bootstrapper, string owner, string repo, string branch)
{
if (bootstrapper != null)
{
bootstrapper.AddSetting(Constants.Site.Owner, owner);
bootstrapper.AddSetting(Constants.Site.Repository, repo);
bootstrapper.AddSetting(Constants.Site.Branch, branch);
}
return bootstrapper;
}
public static Bootstrapper ConfigureDeployment(this Bootstrapper bootstrapper, string deployBranch)
{
bootstrapper?.AddSetting(Constants.Deployment.TargetBranch, deployBranch);
return bootstrapper;
}
}
}