Removing codegen warning when solution is not present.

--HG--
branch : dev
This commit is contained in:
Andre Rodrigues 2011-02-11 15:03:34 -08:00
parent f29a645d48
commit 2d890f54a0

View File

@ -29,20 +29,18 @@ namespace Orchard.CodeGeneration.Commands {
private static readonly string _orchardWebProj = HostingEnvironment.MapPath("~/Orchard.Web.csproj"); private static readonly string _orchardWebProj = HostingEnvironment.MapPath("~/Orchard.Web.csproj");
private static readonly string _orchardThemesProj = HostingEnvironment.MapPath("~/Themes/Themes.csproj"); private static readonly string _orchardThemesProj = HostingEnvironment.MapPath("~/Themes/Themes.csproj");
private bool includeInSolution = true;
public CodeGenerationCommands( public CodeGenerationCommands(
IExtensionManager extensionManager, IExtensionManager extensionManager,
ISchemaCommandGenerator schemaCommandGenerator) { ISchemaCommandGenerator schemaCommandGenerator) {
_extensionManager = extensionManager; _extensionManager = extensionManager;
_schemaCommandGenerator = schemaCommandGenerator; _schemaCommandGenerator = schemaCommandGenerator;
// Default is to include in the solution when generating modules / themes
IncludeInSolution = true;
} }
[OrchardSwitch] [OrchardSwitch]
public bool IncludeInSolution { public bool IncludeInSolution { get; set; }
get { return includeInSolution; }
set { includeInSolution = value; }
}
[OrchardSwitch] [OrchardSwitch]
public bool CreateProject { get; set; } public bool CreateProject { get; set; }
@ -353,9 +351,6 @@ namespace Orchard.CodeGeneration.Commands {
File.WriteAllText(solutionPath, solutionText); File.WriteAllText(solutionPath, solutionText);
TouchSolution(output); TouchSolution(output);
} }
else {
output.WriteLine(T("Warning: Solution file could not be found at {0}", solutionPath));
}
} }
} }