Permalink
Browse files

Updated VS item templates + added two new ones.

  • Loading branch information...
1 parent a62898f commit e5e8fd969d25977a8b9531f60f9996ea041583ba @jkowalski committed Jun 18, 2011
Showing with 240 additions and 92 deletions.
  1. BIN src/VSIntegration/ItemTemplates/CSharpConsoleNLogConfig.zip
  2. BIN src/VSIntegration/ItemTemplates/CSharpEmptyNLogConfig.zip
  3. BIN src/VSIntegration/ItemTemplates/{CSharpTypicalNLogConfig.zip → CSharpFileNLogConfig.zip}
  4. BIN src/VSIntegration/ItemTemplates/CSharpLogReceiverNLogConfig.zip
  5. BIN src/VSIntegration/ItemTemplates/CSharpNLogViewerNLogConfig.zip
  6. BIN src/VSIntegration/ItemTemplates/VisualBasicConsoleNLogConfig.zip
  7. BIN src/VSIntegration/ItemTemplates/VisualBasicEmptyNLogConfig.zip
  8. BIN src/VSIntegration/ItemTemplates/{WebCSharpTypicalNLogConfig.zip → VisualBasicFileNLogConfig.zip}
  9. BIN src/VSIntegration/ItemTemplates/VisualBasicLogReceiverNLogConfig.zip
  10. BIN src/VSIntegration/ItemTemplates/VisualBasicNLogViewerNLogConfig.zip
  11. BIN src/VSIntegration/ItemTemplates/WebCSharpConsoleNLogConfig.zip
  12. BIN src/VSIntegration/ItemTemplates/WebCSharpEmptyNLogConfig.zip
  13. BIN src/VSIntegration/ItemTemplates/{VisualBasicTypicalNLogConfig.zip → WebCSharpFileNLogConfig.zip}
  14. BIN src/VSIntegration/ItemTemplates/WebCSharpLogReceiverNLogConfig.zip
  15. BIN src/VSIntegration/ItemTemplates/WebCSharpNLogViewerNLogConfig.zip
  16. BIN src/VSIntegration/ItemTemplates/WebVisualBasicConsoleNLogConfig.zip
  17. BIN src/VSIntegration/ItemTemplates/WebVisualBasicEmptyNLogConfig.zip
  18. BIN ...ntegration/ItemTemplates/{WebVisualBasicTypicalNLogConfig.zip → WebVisualBasicFileNLogConfig.zip}
  19. BIN src/VSIntegration/ItemTemplates/WebVisualBasicLogReceiverNLogConfig.zip
  20. BIN src/VSIntegration/ItemTemplates/WebVisualBasicNLogViewerNLogConfig.zip
  21. +2 −2 src/VSIntegration/ItemTemplatesGenerator/ConsoleNLogConfig/MyTemplate.vstemplate
  22. +9 −6 src/VSIntegration/ItemTemplatesGenerator/ConsoleNLogConfig/NLog.config
  23. +7 −4 src/VSIntegration/ItemTemplatesGenerator/EmptyNLogConfig/NLog.config
  24. +2 −2 src/VSIntegration/ItemTemplatesGenerator/{TypicalNLogConfig → FileNLogConfig}/MyTemplate.vstemplate
  25. +4 −1 src/VSIntegration/ItemTemplatesGenerator/{TypicalNLogConfig → FileNLogConfig}/NLog.config
  26. BIN src/VSIntegration/ItemTemplatesGenerator/{TypicalNLogConfig → FileNLogConfig}/__TemplateIcon.ico
  27. +19 −0 src/VSIntegration/ItemTemplatesGenerator/LogReceiverNLogConfig/MyTemplate.vstemplate
  28. +25 −0 src/VSIntegration/ItemTemplatesGenerator/LogReceiverNLogConfig/NLog.config
  29. BIN src/VSIntegration/ItemTemplatesGenerator/LogReceiverNLogConfig/__TemplateIcon.ico
  30. +19 −0 src/VSIntegration/ItemTemplatesGenerator/NLogViewerNLogConfig/MyTemplate.vstemplate
  31. +20 −0 src/VSIntegration/ItemTemplatesGenerator/NLogViewerNLogConfig/NLog.config
  32. BIN src/VSIntegration/ItemTemplatesGenerator/NLogViewerNLogConfig/__TemplateIcon.ico
  33. +1 −1 src/VSIntegration/ItemTemplatesGenerator/generate_variants.pl
  34. +31 −37 tools/Installer/NLog.tt
  35. +96 −32 tools/Installer/NLog.wxs
  36. +5 −7 tools/Installer/NLogWix.csproj
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,8 +1,8 @@
<VSTemplate Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Item">
<TemplateData>
<DefaultName>NLog.config</DefaultName>
- <Name>Console NLog Configuration File</Name>
- <Description>Console NLog configuration file</Description>
+ <Name>NLog Configuration - Console</Name>
+ <Description>NLog configuration file for Console logging</Description>
<ProjectType>$projecttype$</ProjectType>
<ProjectSubType>$projectsubtype$</ProjectSubType>
<SortOrder>10</SortOrder>
@@ -2,11 +2,14 @@
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <targets>
- <target name="console" xsi:type="Console" layout="${message}" />
- </targets>
+ <!-- make sure to set 'Copy To Output Directory' option for this file -->
+ <!-- go to http://nlog-project.org/wiki/Configuration_file for more information -->
- <rules>
- <logger name="*" minlevel="Debug" writeTo="console" />
- </rules>
+ <targets>
+ <target name="console" xsi:type="Console" layout="${message}" />
+ </targets>
+
+ <rules>
+ <logger name="*" minlevel="Debug" writeTo="console" />
+ </rules>
</nlog>
@@ -2,9 +2,12 @@
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <targets>
- </targets>
+ <!-- make sure to set 'Copy To Output Directory' option for this file -->
+ <!-- go to http://nlog-project.org/wiki/Configuration_file for more information -->
- <rules>
- </rules>
+ <targets>
+ </targets>
+
+ <rules>
+ </rules>
</nlog>
@@ -1,8 +1,8 @@
<VSTemplate Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Item">
<TemplateData>
<DefaultName>NLog.config</DefaultName>
- <Name>Typical NLog Configuration File</Name>
- <Description>Typical NLog configuration file</Description>
+ <Name>NLog Configuration - File</Name>
+ <Description>NLog configuration file for File logging</Description>
<ProjectType>$projecttype$</ProjectType>
<ProjectSubType>$projectsubtype$</ProjectSubType>
<SortOrder>10</SortOrder>
@@ -2,7 +2,10 @@
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <targets>
+ <!-- make sure to set 'Copy To Output Directory' option for this file -->
+ <!-- go to http://nlog-project.org/wiki/Configuration_file for more information -->
+
+ <targets>
<target name="file" xsi:type="File" fileName="${basedir}/log.txt" />
</targets>
@@ -0,0 +1,19 @@
+<VSTemplate Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Item">
+ <TemplateData>
+ <DefaultName>NLog.config</DefaultName>
+ <Name>NLog Configuration - LogReceiverService</Name>
+ <Description>NLog configuration file for sending logs to LogReceiverService</Description>
+ <ProjectType>$projecttype$</ProjectType>
+ <ProjectSubType>$projectsubtype$</ProjectSubType>
+ <SortOrder>10</SortOrder>
+ <Icon>__TemplateIcon.ico</Icon>
+ </TemplateData>
+ <TemplateContent>
+ <References>
+ <Reference>
+ <Assembly>NLog</Assembly>
+ </Reference>
+ </References>
+ <ProjectItem SubType="" TargetFileName="NLog.config" ReplaceParameters="true">NLog.config</ProjectItem>
+ </TemplateContent>
+</VSTemplate>
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+
+ <!-- make sure to set 'Copy To Output Directory' option for this file -->
+ <!-- go to http://nlog-project.org/wiki/Configuration_file for more information -->
+
+ <targets>
+ <target name="receiver"
+ xsi:type="LogReceiverService"
+ endpointAddress="http://INSERT_SERVER_URL_HERE"
+ includeEventProperties="true"
+ clientId="${guid:cached=true}">
+ <!--
+ uncomment to pass additional client-side values to the server
+
+ <parameter name="clientNDC" layout="${ndc}" />
+ -->
+ </target>
+ </targets>
+
+ <rules>
+ <logger name="*" minlevel="Debug" writeTo="receiver" />
+ </rules>
+</nlog>
@@ -0,0 +1,19 @@
+<VSTemplate Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Item">
+ <TemplateData>
+ <DefaultName>NLog.config</DefaultName>
+ <Name>NLog Configuration - Remote Log Viewer (log4j,log4net)</Name>
+ <Description>NLog configuration file for sending logs to remote log viewer</Description>
+ <ProjectType>$projecttype$</ProjectType>
+ <ProjectSubType>$projectsubtype$</ProjectSubType>
+ <SortOrder>10</SortOrder>
+ <Icon>__TemplateIcon.ico</Icon>
+ </TemplateData>
+ <TemplateContent>
+ <References>
+ <Reference>
+ <Assembly>NLog</Assembly>
+ </Reference>
+ </References>
+ <ProjectItem SubType="" TargetFileName="NLog.config" ReplaceParameters="true">NLog.config</ProjectItem>
+ </TemplateContent>
+</VSTemplate>
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+
+ <!-- make sure to set 'Copy To Output Directory' option for this file -->
+ <!-- go to http://nlog-project.org/wiki/Configuration_file for more information -->
+
+ <targets>
+ <target name="viewer"
+ xsi:type="NLogViewer"
+ address="tcp://SERVERNAME:PORT"
+ includeCallSite="true"
+ includeSourceInfo="true">
+ </target>
+ </targets>
+
+ <rules>
+ <logger name="*" minlevel="Debug" writeTo="viewer" />
+ </rules>
+</nlog>
@@ -27,7 +27,7 @@ sub replace_in_file
rename("$file.tmp", $file);
}
-@projectTypes = ('Empty','Typical','Console');
+@projectTypes = ('Empty','File','Console','LogReceiver','NLogViewer');
@languages = ('CSharp', 'VisualBasic');
for $projectType (@projectTypes)
View
@@ -414,9 +414,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_CSharpItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_CSharpItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_CSharpItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "CSharpItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_CSharpConsoleNLogConfig.zip" Name="CSharpConsoleNLogConfig.zip" ShortName="NLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_CSharpEmptyNLogConfig.zip" Name="CSharpEmptyNLogConfig.zip" ShortName="NLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_CSharpTypicalNLogConfig.zip" Name="CSharpTypicalNLogConfig.zip" ShortName="NLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "CSharp", "CSharp", ""); #>
</Component>
</Directory>
</DirectoryRef>
@@ -426,9 +424,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VBItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VBItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VBItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VBItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VBConsoleNLogConfig.zip" Name="VisualBasicConsoleNLogConfig.zip" ShortName="VBNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VBEmptyNLogConfig.zip" Name="VisualBasicEmptyNLogConfig.zip" ShortName="VBNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VBTypicalNLogConfig.zip" Name="VisualBasicTypicalNLogConfig.zip" ShortName="VBNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "VisualBasic", "VB", "VB"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -438,9 +434,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_WebCSharpItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_WebCSharpItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_WebCSharpItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "WebCSharpItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_WebCSharpConsoleNLogConfig.zip" Name="CSharpConsoleNLogConfig.zip" ShortName="WebNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_WebCSharpEmptyNLogConfig.zip" Name="CSharpEmptyNLogConfig.zip" ShortName="WebNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_WebCSharpTypicalNLogConfig.zip" Name="CSharpTypicalNLogConfig.zip" ShortName="WebNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "CSharp", "WebCSharp", "Web"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -450,9 +444,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_WebVBItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_WebVBItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_WebVBItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "WebVBItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_WebVBConsoleNLogConfig.zip" Name="WebVisualBasicConsoleNLogConfig.zip" ShortName="VBNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_WebVBEmptyNLogConfig.zip" Name="WebVisualBasicEmptyNLogConfig.zip" ShortName="VBNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_WebVBTypicalNLogConfig.zip" Name="WebVisualBasicTypicalNLogConfig.zip" ShortName="VBNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "WebVisualBasic", "WebVB", "VB"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -462,9 +454,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_CSharpExpressItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_CSharpExpressItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_CSharpExpressItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "CSharpExpressItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_CSharpExpressConsoleNLogConfig.zip" Name="CSharpConsoleNLogConfig.zip" ShortName="NLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_CSharpExpressEmptyNLogConfig.zip" Name="CSharpEmptyNLogConfig.zip" ShortName="NLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_CSharpExpressTypicalNLogConfig.zip" Name="CSharpTypicalNLogConfig.zip" ShortName="NLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "CSharp", "CSharpExpress", ""); #>
</Component>
</Directory>
</DirectoryRef>
@@ -474,9 +464,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VBExpressItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VBExpressItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VBExpressItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VBExpressItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VBExpressConsoleNLogConfig.zip" Name="VisualBasicConsoleNLogConfig.zip" ShortName="NLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VBExpressEmptyNLogConfig.zip" Name="VisualBasicEmptyNLogConfig.zip" ShortName="NLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VBExpressTypicalNLogConfig.zip" Name="VisualBasicTypicalNLogConfig.zip" ShortName="NLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "VisualBasic", "VBExpress", ""); #>
</Component>
</Directory>
</DirectoryRef>
@@ -486,9 +474,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VWDCSharpItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VWDCSharpItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VWDCSharpItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VWDCSharpItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VWDCSharpConsoleNLogConfig.zip" Name="CSharpConsoleNLogConfig.zip" ShortName="NLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VWDCSharpEmptyNLogConfig.zip" Name="CSharpEmptyNLogConfig.zip" ShortName="NLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VWDCSharpTypicalNLogConfig.zip" Name="CSharpTypicalNLogConfig.zip" ShortName="NLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "CSharp", "VWDCSharp", ""); #>
</Component>
</Directory>
</DirectoryRef>
@@ -498,9 +484,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VWDVBItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VWDVBItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VWDVBItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VWDVBItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VWDVBConsoleNLogConfig.zip" Name="VisualBasicConsoleNLogConfig.zip" ShortName="VBNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VWDVBEmptyNLogConfig.zip" Name="VisualBasicEmptyNLogConfig.zip" ShortName="VBNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VWDVBTypicalNLogConfig.zip" Name="VisualBasicTypicalNLogConfig.zip" ShortName="VBNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "VisualBasic", "VWDVB", "VB"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -510,9 +494,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VWDWebCSharpItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VWDWebCSharpItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VWDWebCSharpItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VWDWebCSharpItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VWDWebCSharpConsoleNLogConfig.zip" Name="WebCSharpConsoleNLogConfig.zip" ShortName="WebNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VWDWebCSharpEmptyNLogConfig.zip" Name="WebCSharpEmptyNLogConfig.zip" ShortName="WebNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VWDWebCSharpTypicalNLogConfig.zip" Name="WebCSharpTypicalNLogConfig.zip" ShortName="WebNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "WebCSharp", "VWDWebCSharp", "Web"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -522,9 +504,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VWDWebVBItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VWDWebVBItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VWDWebVBItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VWDWebVBItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VWDWebVBConsoleNLogConfig.zip" Name="WebVisualBasicConsoleNLogConfig.zip" ShortName="VBNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VWDWebVBEmptyNLogConfig.zip" Name="WebVisualBasicEmptyNLogConfig.zip" ShortName="VBNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VWDWebVBTypicalNLogConfig.zip" Name="WebVisualBasicTypicalNLogConfig.zip" ShortName="VBNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "WebVisualBasic", "VWDWebVB", "VB"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -536,9 +516,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VPDCSharpItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VPDCSharpItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VPDCSharpItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VPDCSharpItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VPDCSharpConsoleNLogConfig.zip" Name="CSharpConsoleNLogConfig.zip" ShortName="NLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VPDCSharpEmptyNLogConfig.zip" Name="CSharpEmptyNLogConfig.zip" ShortName="NLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VPDCSharpTypicalNLogConfig.zip" Name="CSharpTypicalNLogConfig.zip" ShortName="NLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "CSharp", "VPDCSharp", ""); #>
</Component>
</Directory>
</DirectoryRef>
@@ -548,9 +526,7 @@ foreach (var vs in visualStudioVersions) {
<DirectoryRef Id="VS<#= vs.ReleaseName #>_VPDVBItemTemplates">
<Directory Id="VS<#= vs.ReleaseName #>_VPDVBItemTemplates_NLog" Name="NLog" FileSource="$(var.NLogSourcePath)\src\VSIntegration\ItemTemplates">
<Component Id="VS<#= vs.ReleaseName #>_VPDVBItemTemplates" Guid="<#= GetGuid(vs.ReleaseName, "VPDVBItemTemplates") #>">
- <File Id="VS<#= vs.ReleaseName #>_VPDVBConsoleNLogConfig.zip" Name="VisualBasicConsoleNLogConfig.zip" ShortName="VBNLog1.zip" KeyPath="yes" />
- <File Id="VS<#= vs.ReleaseName #>_VPDVBEmptyNLogConfig.zip" Name="VisualBasicEmptyNLogConfig.zip" ShortName="VBNLog2.zip" />
- <File Id="VS<#= vs.ReleaseName #>_VPDVBTypicalNLogConfig.zip" Name="VisualBasicTypicalNLogConfig.zip" ShortName="VBNLog3.zip" />
+<# PrintTemplates(vs.ReleaseName, "VisualBasic", "VPDVB", "VB"); #>
</Component>
</Directory>
</DirectoryRef>
@@ -697,7 +673,25 @@ foreach (var vs in visualStudioVersions) {
<UIRef Id="WixUI_Mondo" />
</Product>
</Wix>
-<#+
+<#+
+
+void PrintTemplates(string releaseName, string language, string shortLanguage, string specifier)
+{
+ var itemTemplateNames = new []
+ {
+ "Console",
+ "Empty",
+ "File",
+ "LogReceiver",
+ "NLogViewer",
+ };
+
+ for (int i = 0; i < itemTemplateNames.Length; i++) {
+ string templateName = itemTemplateNames[i];
+#>
+ <File Id="VS<#= releaseName #>_<#= shortLanguage #><#= templateName #>NLogConfig.zip" Name="<#= language #><#= templateName #>NLogConfig.zip" ShortName="<#= specifier #>NLog<#= (i + 1) #>.zip" <#= (i == 0) ? "KeyPath=\"yes\" " : "" #>/>
+<#+ }
+}
string GuidNamespace = "{417548C6-D8AB-4f95-9BAE-B0D60D9C8529}";
Oops, something went wrong.

0 comments on commit e5e8fd9

Please sign in to comment.