mirror of https://github.com/abpframework/abp.git
4 changed files with 50 additions and 36 deletions
@ -0,0 +1,49 @@ |
|||
using System.Collections.Generic; |
|||
using Volo.Abp.Cli.ProjectBuilding.Building; |
|||
using Volo.Abp.Cli.ProjectBuilding.Building.Steps; |
|||
|
|||
namespace Volo.Abp.Cli.ProjectBuilding.Templates.MvcModule |
|||
{ |
|||
public class MvcModuleTemplate : TemplateInfo |
|||
{ |
|||
/// <summary>
|
|||
/// "mvc-module".
|
|||
/// </summary>
|
|||
public const string TemplateName = "mvc-module"; |
|||
|
|||
public MvcModuleTemplate() |
|||
: base(TemplateName) |
|||
{ |
|||
|
|||
} |
|||
|
|||
public override IEnumerable<ProjectBuildPipelineStep> GetCustomSteps(ProjectBuildContext context) |
|||
{ |
|||
var steps = new List<ProjectBuildPipelineStep>(); |
|||
|
|||
DeleteUnrelatedProjects(context, steps); |
|||
|
|||
return steps; |
|||
} |
|||
|
|||
private void DeleteUnrelatedProjects(ProjectBuildContext context, List<ProjectBuildPipelineStep> steps) |
|||
{ |
|||
if (context.BuildArgs.ExtraProperties.ContainsKey("no-ui")) |
|||
{ |
|||
steps.Add(new RemoveProjectFromSolutionStep( |
|||
"MyCompanyName.MyProjectName.Web" |
|||
)); |
|||
|
|||
steps.Add(new RemoveProjectFromSolutionStep( |
|||
"MyCompanyName.MyProjectName.Web.Host", |
|||
projectFolderPath: "/host/MyCompanyName.MyProjectName.Web.Host" |
|||
)); |
|||
|
|||
steps.Add(new RemoveProjectFromSolutionStep( |
|||
"MyCompanyName.MyProjectName.Web", |
|||
projectFolderPath: "/host/MyCompanyName.MyProjectName.Web.Unified" |
|||
)); |
|||
} |
|||
} |
|||
} |
|||
} |
|||
@ -1,18 +0,0 @@ |
|||
using Volo.Abp.Cli.ProjectBuilding.Building; |
|||
|
|||
namespace Volo.Abp.Cli.ProjectBuilding.Templates |
|||
{ |
|||
public class MvcModuleTemplate : TemplateInfo |
|||
{ |
|||
/// <summary>
|
|||
/// "mvc-module".
|
|||
/// </summary>
|
|||
public const string TemplateName = "mvc-module"; |
|||
|
|||
public MvcModuleTemplate() |
|||
: base(TemplateName) |
|||
{ |
|||
|
|||
} |
|||
} |
|||
} |
|||
@ -1,18 +0,0 @@ |
|||
using Volo.Abp.Cli.ProjectBuilding.Building; |
|||
|
|||
namespace Volo.Abp.Cli.ProjectBuilding.Templates |
|||
{ |
|||
public class ServiceTemplate : TemplateInfo |
|||
{ |
|||
/// <summary>
|
|||
/// "service".
|
|||
/// </summary>
|
|||
public const string TemplateName = "service"; |
|||
|
|||
public ServiceTemplate() |
|||
: base(TemplateName) |
|||
{ |
|||
|
|||
} |
|||
} |
|||
} |
|||
Loading…
Reference in new issue