我无法发布 ASP.NET 项目,即使我可以构建它



一段时间前,我使用发布配置文件(.pubxml(发布一个ASP.NET项目时做得很好,突然在.pubxml中做了一个小更改后,我收到了1000多条错误消息,尽管我可以在本地构建和运行该项目。

这是.pubxml

<?xml version="1.0" encoding="utf-8"?>
<!--
This file is used by the publish/package process of your Web project. You can customize the behavior of this process
by editing this MSBuild file. In order to learn more about this please visit https://go.microsoft.com/fwlink/?LinkID=208121. 
-->
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<MsDeploySkipRules Include="CustomSkipFolder">
<ObjectName>dirPath</ObjectName>
<AbsolutePath>Temp</AbsolutePath>
</MsDeploySkipRules>
<MsDeploySkipRules Include="CustomSkipFolder">
<ObjectName>dirPath</ObjectName>
<AbsolutePath>Uploads</AbsolutePath>
</MsDeploySkipRules>

<!--<Content Update="TempImages/**" CopyToPublishDirectory="Never" />-->
<MsDeploySkipRules Include="CustomSkipFolder">
<ObjectName>dirPath</ObjectName>
<AbsolutePath>TempImages</AbsolutePath>
</MsDeploySkipRules>
<MsDeploySkipRules Include="CustomSkipFile">
<ObjectName>filePath</ObjectName>
<AbsolutePath>Web.config</AbsolutePath>
</MsDeploySkipRules>
<MsDeploySkipRules Include="CustomSkipFile">
<ObjectName>filePath</ObjectName>
<AbsolutePath>ConfigConn.xml</AbsolutePath>
</MsDeploySkipRules>
</ItemGroup>
<PropertyGroup>
<WebPublishMethod>FileSystem</WebPublishMethod>
<LastUsedBuildConfiguration>Release</LastUsedBuildConfiguration>
<LastUsedPlatform>Any CPU</LastUsedPlatform>
<SiteUrlToLaunchAfterPublish />
<LaunchSiteAfterPublish>True</LaunchSiteAfterPublish>
<PrecompileBeforePublish>True</PrecompileBeforePublish>
<EnableUpdateable>True</EnableUpdateable>
<DebugSymbols>False</DebugSymbols>
<WDPMergeOption>MergeAllPagesAndControlToASingleAssembly</WDPMergeOption>
<UseMerge>True</UseMerge>
<ContentAssemblyName>EspiaWeb_deploy</ContentAssemblyName>
<ExcludeApp_Data>True</ExcludeApp_Data>
<!--<ExcludeFilesFromDeployment>Web.config;ConfigConn.xml</ExcludeFilesFromDeployment>-->
<ExcludeFoldersFromDeployment>.vs</ExcludeFoldersFromDeployment>
<!--<ExcludeFoldersFromDeployment>.vs;Temp;Uploads;TempImages</ExcludeFoldersFromDeployment>-->
<publishUrl>W:Documentosespiaupd</publishUrl>
<DeleteExistingFiles>False</DeleteExistingFiles>
</PropertyGroup>
</Project>

这只是我收到的1000条错误消息中的5条

LogInExternoWeb ReferencesReferenciaUsuarioReference.cs(742,153): error CS0246: The type or namespace name 'ResponseNamespace' could not be found (are you missing a using directive or an assembly reference?) [W:AxonProyectosespiaWebespiaWebespiaWeb.csproj]
LogInExternoWeb ReferencesReferenciaUsuarioReference.cs(742,196): error CS0246: The type or namespace name 'Use' could not be found (are you missing a using directive or an assembly reference?) [W:AxonProyectosespiaWebespiaWebespiaWeb.csproj]
LogInExternoWeb ReferencesReferenciaUsuarioReference.cs(742,200): error CS0234: The type or namespace name 'Services' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) [W:AxonProyectosespiaWebespiaWebespiaWeb.csproj]
LogInExternoWeb ReferencesReferenciaUsuarioReference.cs(742,256): error CS0246: The type or namespace name 'ParameterStyle' could not be found (are you missing a using directive or an assembly reference?) [W:AxonProyectosespiaWebespiaWebespiaWeb.csproj]
LogInExternoWeb ReferencesReferenciaUsuarioReference.cs(742,271): error CS0234: The type or namespace name 'Services' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) [W:AxonProyectosespiaWebespiaWebespiaWeb.csproj]

如果右键单击项目并转到"发布",您应该能够创建一个新的"发布"配置文件。此外,您应该能够在GUI中查看旧的发布配置文件。尝试将旧值复制到新值?

相关内容

  • 没有找到相关文章

最新更新