123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242 |
- <!--
- ***********************************************************************************************
- Microsoft.Web.Publishing.AllFilesInTheProject.targets
- WARNING: DO NOT MODIFY this file unless you are knowledgeable about MSBuild and have
- created a backup copy. Incorrect changes to this file will make it
- impossible to load or build your web deploy projects from the command-line or the IDE.
- This file defines the steps in the standard package/publish process for collecting only project files .
- Copyright (C) Microsoft Corporation. All rights reserved.
- ***********************************************************************************************
- -->
- <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
- <!--ImportBefore Extension-->
- <PropertyGroup>
- <ImportByWildcardBeforeMicrosoftWebPublishingAllFilesInTheProjectTargets Condition="'$(ImportByWildcardBeforeMicrosoftWebPublishingAllFilesInTheProjectTargets)'==''">true</ImportByWildcardBeforeMicrosoftWebPublishingAllFilesInTheProjectTargets>
- </PropertyGroup>
- <Import Project="$(MSBuildThisFileDirectory)\$(MSBuildThisFileName)\ImportBefore\*" Condition="'$(ImportByWildcardBeforeMicrosoftWebPublishingAllFilesInTheProjectTargets)' == 'true' and exists('$(MSBuildThisFileDirectory)\$(MSBuildThisFileName)\ImportBefore')"/>
- <!--The following property need to set before import of Microsoft.Web.Publishing.OnlyFilesToRunTheApp.targets or it will set the property first-->
- <PropertyGroup>
- <!--Overwrite the default behavior. Don't remove the web.debug.config -->
- <ExcludeTransformAssistFilesFromPublish Condition="'$(ExcludeTransformAssistFilesFromPublish)'==''">False</ExcludeTransformAssistFilesFromPublish>
- </PropertyGroup>
- <!--We need all of the item in the minimum run web needed-->
- <Import Project="Microsoft.Web.Publishing.OnlyFilesToRunTheApp.targets"/>
- <PropertyGroup>
- <PublishPipelineCollectFilesCore>
- $(PublishPipelineCollectFilesCore);
- CollectFilesFromCompile;
- CollectFilesFromEmbeddedResource;
- CollectFilesFromNone;
- CollectFilesFromBaseApplicationManifest;
- CollectFilesFromProjectFile;
- </PublishPipelineCollectFilesCore>
- </PropertyGroup>
- <!--MSBuild target does not have a good way to identify all item in the project yet.
- MSBuild team is working on this. At the same time, we are working backward from only known common item collection from
- The following is base on http://msdn.microsoft.com/en-us/library/bb629388.aspx for common project item.
- Note that Content Collection is already in the Microsoft.Web.Publishing.OnlyFilesToRunTheApp.targets-->
-
- <!--********************************************************************-->
- <!-- Task CollectFilesFromCompile -->
- <!--********************************************************************-->
- <PropertyGroup>
- <CollectFilesFromCompileDependsOn>
- $(OnBeforeCollectFilesFromCompile);
- $(CollectFilesFromCompileDependsOn);
- </CollectFilesFromCompileDependsOn>
- </PropertyGroup>
- <Target Name="CollectFilesFromCompile"
- DependsOnTargets="$(CollectFilesFromCompileDependsOn)"
- Condition="'@(Compile)'!=''">
- <!--Get Localized string before display message-->
- <GetPublishingLocalizedString
- ID="PublishLocalizedString_GatherSpecificItemsFromProject"
- ArgumentCount="1"
- Arguments="Compile"
- LogType="Message" />
- <Message Text="@(Compile)" />
-
- <ItemGroup>
- <FilesForPackagingFromProject Include="@(Compile)" Condition="'%(Compile.Link)'==''">
- <DestinationRelativePath>%(Compile.Identity)</DestinationRelativePath>
- <FromTarget>CollectFilesFromCompile</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- <FilesForPackagingFromProject Include="@(Compile)" Condition="'%(Compile.Link)'!='' And $(EnableCollectLinkFilesInProject)">
- <DestinationRelativePath>%(Compile.Link)</DestinationRelativePath>
- <FromTarget>CollectFilesFromCompile</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- <Exclude>$(ExcludeLinkFilesInProject)</Exclude>
- <ProjectFileType>Link</ProjectFileType>
- </FilesForPackagingFromProject>
- </ItemGroup>
- <CallTarget Targets="$(OnAfterCollectFilesFromCompile)" RunEachTargetSeparately="false" />
- </Target>
- <!--********************************************************************-->
- <!-- Task CollectFilesFromEmbeddedResource -->
- <!--********************************************************************-->
- <PropertyGroup>
- <CollectFilesFromEmbeddedResourceDependsOn>
- $(OnBeforeCollectFilesFromEmbeddedResource);
- $(CollectFilesFromEmbeddedResourceDependsOn);
- </CollectFilesFromEmbeddedResourceDependsOn>
- </PropertyGroup>
- <Target Name="CollectFilesFromEmbeddedResource"
- DependsOnTargets="$(CollectFilesFromEmbeddedResourceDependsOn)"
- Condition="'@(EmbeddedResource)'!=''">
- <!--Get Localized string before display message-->
- <GetPublishingLocalizedString
- ID="PublishLocalizedString_GatherSpecificItemsFromProject"
- ArgumentCount="1"
- Arguments="EmbeddedResource"
- LogType="Message" />
- <Message Text="@(EmbeddedResource)" />
- <ItemGroup>
- <FilesForPackagingFromProject Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.Link)'==''">
- <DestinationRelativePath>%(EmbeddedResource.Identity)</DestinationRelativePath>
- <FromTarget>CollectFilesFromEmbeddedResource</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- <FilesForPackagingFromProject Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.Link)'!='' And $(EnableCollectLinkFilesInProject)">
- <DestinationRelativePath>%(EmbeddedResource.Link)</DestinationRelativePath>
- <FromTarget>CollectFilesFromEmbeddedResource</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- <Exclude>$(ExcludeLinkFilesInProject)</Exclude>
- <ProjectFileType>Link</ProjectFileType>
- </FilesForPackagingFromProject>
- </ItemGroup>
- <CallTarget Targets="$(OnAfterCollectFilesFromEmbeddedResource)" RunEachTargetSeparately="false" />
- </Target>
- <!--********************************************************************-->
- <!-- Task CollectFilesFromNone -->
- <!--********************************************************************-->
- <PropertyGroup>
- <CollectFilesFromNoneDependsOn>
- $(OnBeforeCollectFilesFromNone);
- $(CollectFilesFromNoneDependsOn);
- </CollectFilesFromNoneDependsOn>
- </PropertyGroup>
- <Target Name="CollectFilesFromNone"
- DependsOnTargets="$(CollectFilesFromNoneDependsOn)"
- Condition="'@(None)'!=''">
- <GetPublishingLocalizedString
- ID="PublishLocalizedString_GatherSpecificItemsFromProject"
- ArgumentCount="1"
- Arguments="None"
- LogType="Message" />
- <Message Text="@(None)" />
-
- <ItemGroup>
- <FilesForPackagingFromProject Include="@(None)" Condition="'%(None.Link)'==''">
- <DestinationRelativePath>%(None.Identity)</DestinationRelativePath>
- <FromTarget>CollectFilesFromNone</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- <FilesForPackagingFromProject Include="@(None)" Condition="'%(None.Link)'!='' And $(EnableCollectLinkFilesInProject)" >
- <DestinationRelativePath>%(None.Link)</DestinationRelativePath>
- <FromTarget>CollectFilesFromNone</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- <Exclude>$(ExcludeLinkFilesInProject)</Exclude>
- <ProjectFileType>Link</ProjectFileType>
- </FilesForPackagingFromProject>
- </ItemGroup>
- <CallTarget Targets="$(OnAfterCollectFilesFromNone)" RunEachTargetSeparately="false" />
- </Target>
- <!--********************************************************************-->
- <!-- Task CollectFilesFromBaseApplicationManifest -->
- <!--********************************************************************-->
- <PropertyGroup>
- <CollectFilesFromBaseApplicationManifestDependsOn>
- $(OnBeforeCollectFilesFromBaseApplicationManifest);
- $(CollectFilesFromBaseApplicationManifestDependsOn);
- </CollectFilesFromBaseApplicationManifestDependsOn>
- </PropertyGroup>
- <Target Name="CollectFilesFromBaseApplicationManifest"
- DependsOnTargets="$(CollectFilesFromBaseApplicationManifestDependsOn)"
- Condition="'@(BaseApplicationManifest)'!=''">
- <!--Get Localized string before display message-->
- <GetPublishingLocalizedString
- ID="PublishLocalizedString_GatherSpecificItemsFromProject"
- ArgumentCount="1"
- Arguments="BaseApplicationManifest"
- LogType="Message" />
- <Message Text="@(BaseApplicationManifest)" />
- <ItemGroup>
- <FilesForPackagingFromProject Include="@(BaseApplicationManifest)" Condition="'%(BaseApplicationManifest.Link)'==''">
- <DestinationRelativePath>%(BaseApplicationManifest.Identity)</DestinationRelativePath>
- <FromTarget>CollectFilesFromBaseApplicationManifest</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- <FilesForPackagingFromProject Include="@(BaseApplicationManifest)" Condition="'%(BaseApplicationManifest.Link)'!='' And $(EnableCollectLinkFilesInProject)">
- <DestinationRelativePath>%(BaseApplicationManifest.Link)</DestinationRelativePath>
- <FromTarget>CollectFilesFromBaseApplicationManifest</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- <Exclude>$(ExcludeLinkFilesInProject)</Exclude>
- <ProjectFileType>Link</ProjectFileType>
- </FilesForPackagingFromProject>
- </ItemGroup>
- <CallTarget Targets="$(OnAfterCollectFilesFromBaseApplicationManifest)" RunEachTargetSeparately="false" />
- </Target>
- <!--********************************************************************-->
- <!-- Task CollectFilesFromProjectFile -->
- <!--********************************************************************-->
- <PropertyGroup>
- <CollectFilesFromProjectFileDependsOn>
- $(OnBeforeCollectFilesFromProjectFile);
- $(CollectFilesFromProjectFileDependsOn);
- </CollectFilesFromProjectFileDependsOn>
- </PropertyGroup>
- <Target Name="CollectFilesFromProjectFile"
- DependsOnTargets="$(CollectFilesFromProjectFileDependsOn)">
- <!--Get Localized string before display message-->
- <GetPublishingLocalizedString
- ID="PublishLocalizedString_GatherSpecificItemsFromProject"
- ArgumentCount="1"
- Arguments="ProjectFiles"
- LogType="Message" />
- <Message Text="$(MSBuildProjectFile);$(MSBuildProjectFile).user" />
- <ItemGroup>
- <FilesForPackagingFromProject Include="$(MSBuildProjectFile)">
- <DestinationRelativePath>$(MSBuildProjectFile)</DestinationRelativePath>
- <FromTarget>CollectFilesFromProjectFile</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- <FilesForPackagingFromProject Include="$(MSBuildProjectFile).user" Condition="Exists('$(MSBuildProjectFile).user')">
- <DestinationRelativePath>$(MSBuildProjectFile).user</DestinationRelativePath>
- <FromTarget>CollectFilesFromProjectFile</FromTarget>
- <Category>ProjectNotRunRequired</Category>
- </FilesForPackagingFromProject>
- </ItemGroup>
- <CallTarget Targets="$(OnAfterCollectFilesFromProjectFile)" RunEachTargetSeparately="false" />
- </Target>
- <!--ImportAfter Extension-->
- <PropertyGroup>
- <ImportByWildcardAfterMicrosoftWebPublishingAllFilesInTheProjectTargets Condition="'$(ImportByWildcardAfterMicrosoftWebPublishingAllFilesInTheProjectTargets)'==''">true</ImportByWildcardAfterMicrosoftWebPublishingAllFilesInTheProjectTargets>
- </PropertyGroup>
- <Import Project="$(MSBuildThisFileDirectory)\$(MSBuildThisFileName)\ImportAfter\*" Condition="'$(ImportByWildcardAfterMicrosoftWebPublishingAllFilesInTheProjectTargets)' == 'true' and exists('$(MSBuildThisFileDirectory)\$(MSBuildThisFileName)\ImportAfter')"/>
- </Project>
|