包/发布在Azure上的错误 [英] Package / Publish error on Azure

查看:159
本文介绍了包/发布在Azure上的错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近从Azure的SDK 1.6(Visual Studio 2010中)天青SDK 2.0(的Visual Studio 2012)升级的Azure项目。该项目将建立与本地机器上没有错误或警告。我可以调试本地计算机上,但我不能打包或获取构建服务器上构建。我得到的错误是:

I've recently upgraded an Azure Project from Azure SDK 1.6 (Visual Studio 2010) to Azure SDK 2.0 (Visual Studio 2012). The project will build with no errors or warnings on the local machine. I can debug on the local machine, but I cannot package or get a build on the build server. The error I get is:

错误MSB4057:目标PipelineTransformPhase并不在项目中存在

error MSB4057: The target "PipelineTransformPhase" does not exist in the project.

我已经证实了C:\\ Program Files文件(x86)的\\的MSBuild \\微软\\ VisualStudio的\\ 11.0 \\ web应用\\ Microsoft.WebApplications.targets文件存在本地和生成服务器上

I've confirmed that the C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplications.targets file exists locally and on the build server.

原始项目指着\\ 10.0 \\路径和我手动改变了到\\ 11.0 \\路径尝试,没有运气来纠正错误。

The original project pointed to the \v10.0\ path and I manually changed that to the \v11.0\ path trying to resolve the error with no luck.

推荐答案

我已经注意到,当项目不能够访问Microsoft.WebApplications.targets文件,它通常说,我们的目标PipelineTransformPhase并不在项目中存在。

I have noticed that when project is not able to access Microsoft.WebApplications.targets file it usually says "The target "PipelineTransformPhase" does not exist in the project."

您需要导入Microsoft.WebApplications.targets文件到项目中。您可以通过在项目中添加以下行做到这一点。

You need to import Microsoft.WebApplications.targets file into the project. You can do it by adding following line in your project.

<Import Project="C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets" />

在导入Microsoft.WebApplication.targets到项目文件,请确保您没有设置明确的条件=假。我见过类似的错误,当Microsoft.WebApplication.targets与条件一起导入到项目=假。

When importing Microsoft.WebApplication.targets into the project file, make sure you don't set explicit Condition="false". I have seen similar error when Microsoft.WebApplication.targets was imported to the project along with Condition="false".

导入Microsoft.WebApplication.targets到项目文件时还有一件事需要考虑,始终确保默认变量$(MSBuildExtensionsPath32)设置为C:\\ Program Files文件(x86)的\\的MSBuild \\。

One more thing to consider when importing Microsoft.WebApplication.targets into project file, always make sure that default variable $(MSBuildExtensionsPath32) is set to "C:\Program Files (x86)\MSBuild\".

这篇关于包/发布在Azure上的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆