forked from loafle/openapi-generator-original
Merge pull request #3954 from jimschubert/aspnet/3680
[aspnet] Fix .sln/.xproj guids
This commit is contained in:
commit
0712ebc33d
3
.gitignore
vendored
3
.gitignore
vendored
@ -143,3 +143,6 @@ samples/client/petstore/typescript-angular/**/typings
|
||||
samples/client/petstore/typescript-fetch/**/dist/
|
||||
samples/client/petstore/typescript-fetch/**/typings
|
||||
|
||||
# aspnet5
|
||||
samples/server/petstore/aspnet5/.vs/
|
||||
|
||||
|
@ -9,10 +9,14 @@ import org.slf4j.LoggerFactory;
|
||||
import java.io.File;
|
||||
import java.util.*;
|
||||
|
||||
import static java.util.UUID.randomUUID;
|
||||
|
||||
public class AspNet5ServerCodegen extends AbstractCSharpCodegen {
|
||||
|
||||
protected String sourceFolder = "src" + File.separator + packageName;
|
||||
|
||||
private final String packageGuid = "{" + randomUUID().toString().toUpperCase() + "}";
|
||||
|
||||
@SuppressWarnings("hiding")
|
||||
protected Logger LOGGER = LoggerFactory.getLogger(AspNet5ServerCodegen.class);
|
||||
|
||||
@ -81,6 +85,8 @@ public class AspNet5ServerCodegen extends AbstractCSharpCodegen {
|
||||
public void processOpts() {
|
||||
super.processOpts();
|
||||
|
||||
additionalProperties.put("packageGuid", packageGuid);
|
||||
|
||||
apiPackage = packageName + ".Controllers";
|
||||
modelPackage = packageName + ".Models";
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion>
|
||||
@ -6,8 +6,8 @@
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" />
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{{projectGuid}}</ProjectGuid>
|
||||
<RootNamespace>Sample</RootNamespace>
|
||||
<ProjectGuid>{{packageGuid}}</ProjectGuid>
|
||||
<RootNamespace>{{packageName}}</RootNamespace>
|
||||
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">.\obj</BaseIntermediateOutputPath>
|
||||
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath>
|
||||
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
||||
|
@ -1,10 +1,7 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 14
|
||||
VisualStudioVersion = 14.0.25420.1
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{815BE834-0656-4C12-84A4-43F2BA4B8BDE}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{AFF6BF88-8A7D-4736-AF81-31BCE86B19BD}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
global.json = global.json
|
||||
@ -18,15 +15,12 @@ Global
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{{packageGuid}}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{{packageGuid}}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{{packageGuid}}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{{packageGuid}}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(NestedProjects) = preSolution
|
||||
{{packageGuid}} = {815BE834-0656-4C12-84A4-43F2BA4B8BDE}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
@ -1,16 +1,13 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 14
|
||||
VisualStudioVersion = 14.0.25420.1
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{815BE834-0656-4C12-84A4-43F2BA4B8BDE}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{AFF6BF88-8A7D-4736-AF81-31BCE86B19BD}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
global.json = global.json
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "IO.Swagger", "src\IO.Swagger\IO.Swagger.xproj", ""
|
||||
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "IO.Swagger", "src\IO.Swagger\IO.Swagger.xproj", "{CF700387-34B9-4172-B648-7535827D5EEB}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
@ -18,15 +15,12 @@ Global
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{3B5990B3-40F1-4148-89B5-84AC71432557}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{CF700387-34B9-4172-B648-7535827D5EEB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{CF700387-34B9-4172-B648-7535827D5EEB}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{CF700387-34B9-4172-B648-7535827D5EEB}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{CF700387-34B9-4172-B648-7535827D5EEB}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(NestedProjects) = preSolution
|
||||
= {815BE834-0656-4C12-84A4-43F2BA4B8BDE}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion>
|
||||
@ -6,8 +6,8 @@
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" />
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid></ProjectGuid>
|
||||
<RootNamespace>Sample</RootNamespace>
|
||||
<ProjectGuid>{CF700387-34B9-4172-B648-7535827D5EEB}</ProjectGuid>
|
||||
<RootNamespace>IO.Swagger</RootNamespace>
|
||||
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">.\obj</BaseIntermediateOutputPath>
|
||||
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath>
|
||||
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
||||
|
Loading…
x
Reference in New Issue
Block a user