我試圖在Visual Studio 2008中構建一個Web部署項目,它保持失敗,我不知道爲什麼。錯誤:Web部署項目失敗構建(Visual Studio 2008)
------ Build started: Project: website_deploy, Configuration: Release Any CPU ------
if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"
'C:\Documents' is not recognized as an internal or external command,
operable program or batch file.
C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(92,7): error MSB3073: The command "if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"" exited with code 1.
Done building project "website_deploy.wdproj" -- FAILED.
========== Build: 1 succeeded or up-to-date, 1 failed, 0 skipped ==========
我在另一臺機器上有相同的項目,它建立得很好。我已經下載Visual Studio 2008 Web Deployment Projects - RTW和安裝Service Pack 1的Visual Studio 2008
編輯:
在錯誤列表,它有Error 1 The command "if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"" exited with code 1.
。我不知道爲什麼它是未來與C:\Documents
作爲該項目的文件夾中沒有空格(C:\Web\Projects\
)
它發生了一個全新的網絡部署項目,通過右鍵點擊該網站,點擊Add Web Deployment Project
上創建的。
編輯(1月29日)。更詳細的輸出,failes每當<exec>
與if exist
用於:
Building with tools version "3.5".
Target "_PrepareForBuild" in file "C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets":
Using "CreateProperty" task from assembly "Microsoft.Build.Tasks.v3.5, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a".
Task "CreateProperty"
Done executing task "CreateProperty".
Task "CreateProperty"
Done executing task "CreateProperty".
Task "CreateProperty"
Done executing task "CreateProperty".
Using "Exec" task from assembly "Microsoft.Build.Tasks.v3.5, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a".
Task "Exec"
Command:
if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"
'C:\Documents' is not recognized as an internal or external command,
operable program or batch file.
C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(92,7): error MSB3073: The command "if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"" exited with code 1.
Done executing task "Exec" -- FAILED.
Done building target "_PrepareForBuild" in project "website_deploy.wdproj" -- FAILED
看起來像它不喜歡在您的C:\ Documents and Settings – RYFN 2010-01-26 15:43:30
空間C:\ Documents沒有被引用到解決方案或項目文件中的任何地方 – SamWM 2010-01-26 17:05:48