The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.
You just have to play with it at the command line. If you can get it working there you will have the "command" required to work from any CI server. That’s about the best I can offer, that’s what I had to do.
It will be specialized according to your individual project and environment. Not the sort of thing you can get from “book learning”. run the build, examine the errorlog, reconfigure accordingly, and repeat until it's error free.
Used to see errors like this often.
First, is the C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets file located in that path on the bamboo server where the build is executing? Is it located on D: or E: instead? (lots of server dudes want to reserve C: for the OS and make you install your build stuff on a different drive which is a really good idea for performance and update management).
Is the path properly quoted (spaces = bad in pathnames, just sayin...)
In general in bamboo, MSBuild fails on good code for one of these reasons:
Look for things like: you haven't saved your targets file to the repository (though it exists in your local copy)
You haven't added the targets file to one of the build files (and therefore it gets excluded even though it exists in the repository).
Another variation is that you have it pointing one place in visual studio but that location doesn't exist in the repository.
My experience with msbuild is that it behaves very differently from the IDE. There are a lot of things that the IDE does for you. Yes, in case you didn't know, Microsoft thinks it's your mother. "Oh here honey, I know what you meant to do. Let me tidy that up for you".
Which is convenient until such time as you try to do a command line build. Don't assume the command line build will work the same way. People will tell you that it will, and they will mostly be wrong.
If you haven't done it already you'll probably have to configure your build files for bamboo and have your local settings different. This can make things confusing but your developer laptop and the bamboo server (assuming you have one) probably aren't cut from the same disk image. And once you do that, don't mess it up by checking in your local settings on top of the bamboo configuration in the repository.
Welcome to your weekly Jira Ops Early access program update, where we’re sharing news and updates on Jira Ops' progress as we work toward our 1.0 release. If you ever want to drop us feedback or idea...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs