Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

When I use the Project -> Export template option in Visual Studio 2017, the resulting ZIP file includes the main project files, but not any of the *.cpp and *.hpp files that I've added. How do I include everything with the template? I should also note that this behavior seems to have changed in an update at some point.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
367 views
Welcome To Ask or Share your Answers For Others

1 Answer

You need to manually edit the .vstemplate file and add <CreateInPlace>true</CreateInPlace> in the <TemplateData> tag so it looks like this:

<VSTemplate Version="3.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Project">
    <TemplateData>
        <Name>TemplateTest</Name>
        <Description><No description available></Description>
        <ProjectType>JavaScript</ProjectType>
        <ProjectSubType>
        </ProjectSubType>
        <SortOrder>1000</SortOrder>
        <CreateNewFolder>true</CreateNewFolder>
        <CreateInPlace>true</CreateInPlace>
        <DefaultName>CodovaTemplateTest</DefaultName>
        <ProvideDefaultName>true</ProvideDefaultName>
        <LocationField>Enabled</LocationField>
        <EnableLocationBrowseButton>true</EnableLocationBrowseButton>
        <Icon>__TemplateIcon.ico</Icon>
  </TemplateData>

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...