Merge pull request #1220 from dotnet/davidfowl/rename-project-json-template

Remove project.json in template to avoid restore
This commit is contained in:
David Fowler 2016-02-03 22:48:06 -08:00
commit a3ee81dbd4
4 changed files with 8 additions and 2 deletions

View file

@ -19,6 +19,12 @@ namespace Microsoft.DotNet.Tools.New
return null;
}
// filename.extension.template
if (parts.Length > 2 && string.Equals("template", parts[parts.Length - 1], StringComparison.OrdinalIgnoreCase))
{
return parts[parts.Length - 3] + "." + parts[parts.Length - 2];
}
// filename.extension
return parts[parts.Length - 2] + "." + parts[parts.Length - 1];
}

View file

@ -10,10 +10,10 @@
"resource": [
"commands/dotnet-new/CSharp_Console/NuGet.Config",
"commands/dotnet-new/CSharp_Console/Program.cs",
"commands/dotnet-new/CSharp_Console/project.json",
"commands/dotnet-new/CSharp_Console/project.json.template",
"commands/dotnet-new/FSharp_Console/NuGet.config",
"commands/dotnet-new/FSharp_Console/Program.fs",
"commands/dotnet-new/FSharp_Console/project.json"
"commands/dotnet-new/FSharp_Console/project.json.template"
],
"dependencies": {
"Newtonsoft.Json": "7.0.1",