{"id":3314,"date":"2010-02-09T17:13:37","date_gmt":"2010-02-09T17:13:37","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/webdev\/2010\/02\/09\/how-to-extend-target-file-to-include-registry-settings-for-web-project-package\/"},"modified":"2010-02-09T17:13:37","modified_gmt":"2010-02-09T17:13:37","slug":"how-to-extend-target-file-to-include-registry-settings-for-web-project-package","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/dotnet\/how-to-extend-target-file-to-include-registry-settings-for-web-project-package\/","title":{"rendered":"How to extend target file to include registry settings for web project package"},"content":{"rendered":"<p>Web project package and deployment targets files are written with extensibility in mind.&#160; User can easily extend a property to include more functionalities in their package by using msbuild targets and properties.&#160; <\/p>\n<p>If we check the Microsoft.Web.Publishing.targets file under \u201c%Program Files%MSBuildMicrosoftVisualStudiov10.0Web\u201d, we can see the following, which means if file $(WebPublishPipelineProjectName).wpp.targets exists in the project directory, we\u2019ll import it automatically when build package or publish.<\/p>\n<pre class=\"code\">  <span style=\"color: blue\">&lt;!--<\/span><span style=\"color: green\">***************************************************************<\/span><span style=\"color: blue\">--&gt;\n  &lt;!--<\/span><span style=\"color: green\">To allow the Team build to have custom setting for the Web Application project without change the project file  <\/span><span style=\"color: blue\">--&gt;\n  &lt;!--<\/span><span style=\"color: green\">by default, if user have a file call $(WebPublishPipelineProjectName).wpp.targets, we will import these setting in before we start  <\/span><span style=\"color: blue\">--&gt;\n  &lt;!--<\/span><span style=\"color: green\">***************************************************************<\/span><span style=\"color: blue\">--&gt;\n  &lt;<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">WebPublishPipelineCustomizeTargetFile <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(WebPublishPipelineCustomizeTargetFile)'==''<\/span>&quot;<span style=\"color: blue\">&gt;<\/span>$(WebPublishPipelineProjectDirectory)$(WebPublishPipelineProjectName).wpp.targets<span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">WebPublishPipelineCustomizeTargetFile<\/span><span style=\"color: blue\">&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">Import <\/span><span style=\"color: red\">Project<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">$(WebPublishPipelineCustomizeTargetFile)<\/span>&quot; <span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">Exists($(WebPublishPipelineCustomizeTargetFile))<\/span>&quot;<span style=\"color: blue\">\/&gt;\n\n<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a><\/p>\n<p>Here\u2019s steps to create a customized target file to include some registry keys in the web package by using <a href=\"http:\/\/technet.microsoft.com\/en-us\/library\/dd569085(WS.10).aspx\">msdeploy\u2019s regKey provider<\/a>. (The link contains the functionality and limitation of regKey provider)<\/p>\n<p>&#160;<\/p>\n<p>1. Create a file WebApplicationName.wpp.targets in the same folder as your web project (e.g. if the project file is WebApplication1.vbproj, then name the file WebApplication1.wpp.targets) with following content:<\/p>\n<pre class=\"code\"><span style=\"color: blue\">&lt;!--<\/span><span style=\"color: green\">********************************************************************<\/span><span style=\"color: blue\">--&gt;\n&lt;!-- <\/span><span style=\"color: green\">Task CollectRegKeysForPackage <\/span><span style=\"color: blue\">--&gt;\n&lt;!-- <\/span><span style=\"color: green\">RegKey reference: http:\/\/technet.microsoft.com\/en-us\/library\/dd569085(WS.10).aspx <\/span><span style=\"color: blue\">--&gt;\n&lt;!--<\/span><span style=\"color: green\">********************************************************************<\/span><span style=\"color: blue\">--&gt;\n&lt;<\/span><span style=\"color: #a31515\">Project <\/span><span style=\"color: red\">xmlns<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">http:\/\/schemas.microsoft.com\/developer\/msbuild\/2003<\/span>&quot;<span style=\"color: blue\">&gt;\n  &lt;<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;!--<\/span><span style=\"color: green\">Targets get execute before this Target<\/span><span style=\"color: blue\">--&gt;\n    &lt;<\/span><span style=\"color: #a31515\">OnBeforeCollectRegKeysForPackage <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(OnBeforeCollectRegKeysForPackage)'==''<\/span>&quot;<span style=\"color: blue\">&gt;\n    &lt;\/<\/span><span style=\"color: #a31515\">OnBeforeCollectRegKeysForPackage<\/span><span style=\"color: blue\">&gt;\n    &lt;!--<\/span><span style=\"color: green\">Targets get execute after this Target<\/span><span style=\"color: blue\">--&gt;\n    &lt;<\/span><span style=\"color: #a31515\">OnAfterCollectRegKeysForPackage <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(OnAfterCollectRegKeysForPackage)'==''<\/span>&quot;<span style=\"color: blue\">&gt;\n    &lt;\/<\/span><span style=\"color: #a31515\">OnAfterCollectRegKeysForPackage<\/span><span style=\"color: blue\">&gt;\n\n    &lt;<\/span><span style=\"color: #a31515\">CollectRegKeysForPackageDependsOn <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(CollectRegKeysForPackageDependsOn)'==''<\/span>&quot;<span style=\"color: blue\">&gt;\n      <\/span>$(OnBeforeCollectRegKeysForPackage);\n      Build;\n    <span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">CollectRegKeysForPackageDependsOn<\/span><span style=\"color: blue\">&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">IncludeRegKeyForMyProject <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(IncludeRegKeyForMyProject)'==''<\/span>&quot;<span style=\"color: blue\">&gt;<\/span>False<span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">IncludeRegKeyForMyProject<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">MyRegKeyPath <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(MyRegKeyPath)'==''<\/span>&quot;<span style=\"color: blue\">&gt;&lt;\/<\/span><span style=\"color: #a31515\">MyRegKeyPath<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">AfterAddContentPathToSourceManifest <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(AfterAddContentPathToSourceManifest)'==''<\/span>&quot;<span style=\"color: blue\">&gt;\n      <\/span>$(AfterAddContentPathToSourceManifest);\n      CollectRegKeysForPackage;\n    <span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">AfterAddContentPathToSourceManifest<\/span><span style=\"color: blue\">&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">MyRegkeys <\/span><span style=\"color: red\">Include <\/span><span style=\"color: blue\">= <\/span>&quot;<span style=\"color: blue\">$(MyRegKeyPath)<\/span>&quot;<span style=\"color: blue\">\/&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">Target <\/span><span style=\"color: red\">Name<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">CollectRegKeysForPackage<\/span>&quot;\n          <span style=\"color: red\">DependsOnTargets<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">$(CollectRegKeysForPackageDependsOn)<\/span>&quot;\n          <span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">$(IncludeRegKeyForMyProject) AND '$(MyRegKeyPath)'!=''<\/span>&quot;<span style=\"color: blue\">&gt;\n<\/span><span style=\"color: blue\">\n    &lt;<\/span><span style=\"color: #a31515\">Message <\/span><span style=\"color: red\">Text<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">Adding %(MyRegkeys.Identity)<\/span>&quot; <span style=\"color: blue\">\/&gt;\n    &lt;<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n      &lt;<\/span><span style=\"color: #a31515\">MsDeploySourceManifest <\/span><span style=\"color: red\">Include<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">regkey<\/span>&quot;\n                                 <span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">$(IncludeRegKeyForMyProject)<\/span>&quot;<span style=\"color: blue\">&gt;\n        &lt;<\/span><span style=\"color: #a31515\">Path<\/span><span style=\"color: blue\">&gt;<\/span>%(MyRegkeys.Identity)<span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">Path<\/span><span style=\"color: blue\">&gt;\n      &lt;\/<\/span><span style=\"color: #a31515\">MsDeploySourceManifest<\/span><span style=\"color: blue\">&gt;\n    &lt;\/<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">CallTarget <\/span><span style=\"color: red\">Targets<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">$(OnAfterCollectRegKeysForPackage)<\/span>&quot; <span style=\"color: red\">RunEachTargetSeparately<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">false<\/span>&quot; <span style=\"color: blue\">\/&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">Target<\/span><span style=\"color: blue\">&gt;\n&lt;\/<\/span><span style=\"color: #a31515\">Project<\/span><span style=\"color: blue\">&gt;\n\n<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a><\/p>\n<p>2. Package the project from command line using parameters such as the following to include multiple registry keys (seperated by ; sign) in the package.<\/p>\n<p>msbuild WebApplication1.vbproj \/target:package \/p:IncludeRegKeyForMyProject=True;MyRegKeyPath=&quot;hkey_current_usercontrol paneldesktopwindowmetrics;hkey_current_usercontrol paneldesktopcolors&quot;<\/p>\n<p>In objdebugpackageWebApplication1.SourceManifest.xml file, you should see two regkey providers are defined:<\/p>\n<pre class=\"code\"><span style=\"color: blue\">&lt;?<\/span><span style=\"color: #a31515\">xml <\/span><span style=\"color: red\">version<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">1.0<\/span>&quot; <span style=\"color: red\">encoding<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">utf-8<\/span>&quot;<span style=\"color: blue\">?&gt;\n&lt;<\/span><span style=\"color: #a31515\">sitemanifest<\/span><span style=\"color: blue\">&gt;\n  &lt;<\/span><span style=\"color: #a31515\">regkey <\/span><span style=\"color: red\">path<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">hkey_current_usercontrol paneldesktopwindowmetrics<\/span>&quot; <span style=\"color: blue\">\/&gt;\n  &lt;<\/span><span style=\"color: #a31515\">regkey <\/span><span style=\"color: red\">path<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">hkey_current_usercontrol paneldesktopcolors<\/span>&quot; <span style=\"color: blue\">\/&gt;\n  &lt;<\/span><span style=\"color: #a31515\">IisApp <\/span><span style=\"color: red\">path<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">D:tempWebApplication1WebApplication1objDebugPackagePackageTmp<\/span>&quot; <span style=\"color: red\">managedRuntimeVersion<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">v4.0<\/span>&quot; <span style=\"color: blue\">\/&gt;\n  &lt;<\/span><span style=\"color: #a31515\">setAcl <\/span><span style=\"color: red\">path<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">D:tempWebApplication1WebApplication1objDebugPackagePackageTmp<\/span>&quot; <span style=\"color: red\">setAclResourceType<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">Directory<\/span>&quot; <span style=\"color: blue\">\/&gt;\n  &lt;<\/span><span style=\"color: #a31515\">setAcl <\/span><span style=\"color: red\">path<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">D:tempWebApplication1WebApplication1objDebugPackagePackageTmp<\/span>&quot; <span style=\"color: red\">setAclUser<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">anonymousAuthenticationUser<\/span>&quot; <span style=\"color: red\">setAclResourceType<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">Directory<\/span>&quot; <span style=\"color: blue\">\/&gt;\n&lt;\/<\/span><span style=\"color: #a31515\">sitemanifest<\/span><span style=\"color: blue\">&gt;\n<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a><\/p>\n<p>3. To proves it works, we change the hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth from \u2013285 to \u2013284, then we deploy the package locally from command line:<\/p>\n<blockquote>\n<p>WebApplication1.deploy.cmd \/y<\/p>\n<\/blockquote>\n<p>4. We see the following line which showed that the corresponding registry is updated.<\/p>\n<p>Info: Updating regValue (hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth).<\/p>\n<p>5. Or we can import the package from IIS<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/16\/2019\/02\/image_2.png\"><img decoding=\"async\" style=\"border-right-width: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px\" title=\"image\" border=\"0\" alt=\"image\" src=\"https:\/\/devblogs.microsoft.com\/dotnet\/wp-content\/uploads\/sites\/10\/2010\/02\/image_thumb-3.png\" width=\"684\" height=\"446\" \/><\/a> <\/p>\n<p>After installation finishes, from its details tab, there are the following messages:<\/p>\n<p>[2\/9\/2010 11:55:05 AM] Source regValue (hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth) does not match destination (hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth) differing in attributes (value[&#8216;-285&#8242;,&#8217;-284&#8242;]). Update pending. \n  <br \/>[2\/9\/2010 11:55:05 AM] Source regValue (hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth) replaced with changed attributes (parameters) because of rule EnvironmentVariableNormalize. <\/p>\n<p>[2\/9\/2010 11:55:05 AM] Updating regValue (hkey_current_usercontrol paneldesktopwindowmetricsMenuWidth).<\/p>\n<p>&#160;<\/p>\n<p>If you simply want to hardcode the registry keys for your project and don\u2019t want to worry about more extensions, here\u2019s a simplified version:<\/p>\n<pre class=\"code\"><span style=\"color: blue\">&lt;!--<\/span><span style=\"color: green\">********************************************************************<\/span><span style=\"color: blue\">--&gt;\n&lt;!-- <\/span><span style=\"color: green\">Task CollectRegKeysForPackage <\/span><span style=\"color: blue\">--&gt;\n&lt;!-- <\/span><span style=\"color: green\">RegKey reference: http:\/\/technet.microsoft.com\/en-us\/library\/dd569085(WS.10).aspx <\/span><span style=\"color: blue\">--&gt;\n&lt;!--<\/span><span style=\"color: green\">********************************************************************<\/span><span style=\"color: blue\">--&gt;\n&lt;<\/span><span style=\"color: #a31515\">Project <\/span><span style=\"color: red\">xmlns<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">http:\/\/schemas.microsoft.com\/developer\/msbuild\/2003<\/span>&quot;<span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;!-- <\/span><span style=\"color: green\">Extends the AfterAddContentPathToSourceManifest action do also collect registry keys<\/span><span style=\"color: blue\">--&gt;\n    &lt;!-- <\/span><span style=\"color: green\">Hard code <\/span><span style=\"color: blue\">--&gt;\n    &lt;<\/span><span style=\"color: #a31515\">MyRegKeyPath <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(MyRegKeyPath)'==''<\/span>&quot;<span style=\"color: blue\">&gt;<\/span>hkey_current_usercontrol paneldesktopwindowmetrics;hkey_current_usercontrol paneldesktopcolors<span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">MyRegKeyPath<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">AfterAddContentPathToSourceManifest <\/span><span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(AfterAddContentPathToSourceManifest)'==''<\/span>&quot;<span style=\"color: blue\">&gt;\n      <\/span>$(AfterAddContentPathToSourceManifest);\n      CollectRegKeysForPackage;\n    <span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">AfterAddContentPathToSourceManifest<\/span><span style=\"color: blue\">&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">PropertyGroup<\/span><span style=\"color: blue\">&gt;\n\n  &lt;<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">MyRegkeys <\/span><span style=\"color: red\">Include <\/span><span style=\"color: blue\">= <\/span>&quot;<span style=\"color: blue\">$(MyRegKeyPath)<\/span>&quot;<span style=\"color: blue\">\/&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n  \n<\/span><\/pre>\n<pre class=\"code\">  <span style=\"color: blue\">&lt;<\/span><span style=\"color: #a31515\">Target <\/span><span style=\"color: red\">Name<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">CollectRegKeysForPackage<\/span>&quot; <span style=\"color: red\">Condition<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">'$(MyRegKeyPath)'!=''<\/span>&quot;<span style=\"color: blue\">&gt;\n    &lt;<\/span><span style=\"color: #a31515\">Message <\/span><span style=\"color: red\">Text<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">Adding %(MyRegkeys.Identity)<\/span>&quot; <span style=\"color: blue\">\/&gt;\n    &lt;<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n      &lt;<\/span><span style=\"color: #a31515\">MsDeploySourceManifest <\/span><span style=\"color: red\">Include<\/span><span style=\"color: blue\">=<\/span>&quot;<span style=\"color: blue\">regkey<\/span>&quot;<span style=\"color: blue\">&gt;\n        &lt;<\/span><span style=\"color: #a31515\">Path<\/span><span style=\"color: blue\">&gt;<\/span>%(MyRegkeys.Identity)<span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">Path<\/span><span style=\"color: blue\">&gt;\n      &lt;\/<\/span><span style=\"color: #a31515\">MsDeploySourceManifest<\/span><span style=\"color: blue\">&gt;\n    &lt;\/<\/span><span style=\"color: #a31515\">ItemGroup<\/span><span style=\"color: blue\">&gt;\n  &lt;\/<\/span><span style=\"color: #a31515\">Target<\/span><span style=\"color: blue\">&gt;\n<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a><\/p>\n<pre class=\"code\"><span style=\"color: blue\"><\/span><span style=\"color: blue\">&lt;\/<\/span><span style=\"color: #a31515\">Project<\/span><span style=\"color: blue\">&gt;\n<\/span><\/pre>\n<p>Note: if you change an existing target file (this.wpp.targets).&#160; You need to restart VS IDE to allow the target file cache to be unloaded and reloaded, in order for package\/publish using the change.<\/p>\n<pre class=\"code\"><span style=\"color: blue\">Xinyang Qiu | Visual Web Devloper<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a><\/p>\n<pre class=\"code\"><span style=\"color: blue\"><\/span><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Web project package and deployment targets files are written with extensibility in mind.&#160; User can easily extend a property to include more functionalities in their package by using msbuild targets and properties.&#160; If we check the Microsoft.Web.Publishing.targets file under \u201c%Program Files%MSBuildMicrosoftVisualStudiov10.0Web\u201d, we can see the following, which means if file $(WebPublishPipelineProjectName).wpp.targets exists in the project [&hellip;]<\/p>\n","protected":false},"author":404,"featured_media":58792,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[197],"tags":[7352,7343,7353,7354,7323,7329],"class_list":["post-3314","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-aspnet","tag-package","tag-publish","tag-target-extension","tag-target-file","tag-visual-studio-2010","tag-web-deployment"],"acf":[],"blog_post_summary":"<p>Web project package and deployment targets files are written with extensibility in mind.&#160; User can easily extend a property to include more functionalities in their package by using msbuild targets and properties.&#160; If we check the Microsoft.Web.Publishing.targets file under \u201c%Program Files%MSBuildMicrosoftVisualStudiov10.0Web\u201d, we can see the following, which means if file $(WebPublishPipelineProjectName).wpp.targets exists in the project [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/posts\/3314","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/users\/404"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/comments?post=3314"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/posts\/3314\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/media\/58792"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/media?parent=3314"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/categories?post=3314"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/dotnet\/wp-json\/wp\/v2\/tags?post=3314"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}