For a Visual Studio Team Services Build Definition step Build Solution (Visual Studio Build), how would one structure a pattern to both include and exclude files/folders. For example, to include all .sln files I'm able to use **\*.sln and to exclude node_modules I could us !node_modules. How could I combine this within the Solution field of the Build Solution edit UI?
**\*.sln,!node_modules returns an invalid pattern error. Is there a separator that I can use to specify multiple glob patterns?
Thank you for any help you can provide.
Try to use this value instead:
**\*.sln;-:**\node_modules\**
Related
I'm in this case, I have a single solution built on Visual Studio 2013. It contains more than 10 projects that reference each others, I need only to build and release 3 projects of them on Azure via Visual Studio Team Services so the question is what is the best approach to do this
Thank you
If they all reference each other than you may need to build all of them. Dependencies will be resolved at build time.
You can reference individual Project files in place of a Solution. You will then need to maintain order yourself.
Just use the same build step for building a Solution, but fill out a Project (.proj) file instead. Control the order by having multiple build steps.
Please read my Suggestions below-
- Copy all the references dll's in one shared folder through Post build event.
- Create new solution according to your deployment needs and take all references from the shared folder in all projects.
- Deploy the solution you want
If the references are project references, you just need to specify the solution file (.sln) to build, otherwise, you need to specify project dependence (Right click your solution=> Project Dependence=>Select a project=>Check the projects’ options that dependence to)
I have X projects in solution:
AllPlatformProject1, AllPlatformProject2...
ProjectOnlyForWindows1, OnlyForWindows2...
ProjectNotLinux1, ProjectNotLinux2...
I want to exclude "OnlyForWindows" and "NotLinux", but how?
I want to use xbuild and be able to do it for all targets.
You can't do it with one sln. Usually people create multiple solutions, even in the same directory.
Everything.sln
WindowsCentric.sln
LinuxCentric.sln
something like that.
The "gotcha" is that......when you add a "reference by project", both projects need to be in the .sln file.
Have you tried using different Configurations to pair with your targets and omit the configurations from the specific projects? Example:
Solution configurations :
LinuxDebug
LinuxRelease
WindowsDebug
WindowsRelease
And then you tell the solution to omit the linux projects from the Windows* configurations and vice versa?
I'll admit, I haven't leveraged xbuild but this approach works in MSBuild if you are using solutions and not traversal proj files. In the case of Traversal proj files you can just add conditionals to the ItemGroup inclusions to omit projects based on a $() property.
As the title says, I want to output 2 .msi files from one project (one is per-user, and the other is per-machine). I have seen in this thread that it can't be done in some conventional way, but perhaps there is a way to do so as some kind of hack in post-build.
I only need to rerun compilation and linking after the original build with slightly changed command line (actually, I need only different Product.wxs file). However, my light and candle command lines are huge, and I would risk making my project hard to maintain if I would hard-code them.
So, in conclusion, I need to know if there is a way to write a command line that would behave the same as Votive does when creating its build command line (getting all the files in project, linking them, passing project dependencies...), only in post build.
P.S.: I also had an idea of getting the whole command line from Votive, and only changing the Product file, that would also help, so if someone has suggestion on how to do it...
Create multiple configurations of your solution / project and set a preprocessor variable to some value for one of the configurations. In your wix source, conditionally include whatever else it is that needs included based on your preprocessor variable.
I want to be able to build only one project in my solution using msbuild /t. The problem occurs when the project name includes a ".", for instance MyProject.Unittests
msbuild reports MSB4057, no matter what I write. I have tried escaping the . with %2e without any success.
I have a similar problem when the project is added to a solution folder with space in the name.
Any help is greatly appreciated.
Good morning'
Team Foundation Server 2010 question.
Do I need to create a Build Definition for every branch I have ?
Is there a way to parametrize 'Workspace' in Team Build 2010 for different branches, so we could just queue a new build specifying the workspace paths?
I tried finding out how TFS retrieves the workspace paths from the workspace used in the build, but the xaml got me clueless since there are parameters for everything except the mapped paths.
Thanks in advance!
Do I need to create a Build Definition for every branch I have ?
No, but you may want to in order to have a cleaner implementation.
Is there a way to parametrize 'Workspace' in Team Build 2010 for
different branches, so we could just queue a new build specifying the
workspace paths?
Yes- but it isn't as straight forward (unless you are using .proj files still).
If you are using the upgrade template and still using proj files:
Building multiple branches, can I use paramters to identify the target branch.
If you are not using the upgrade template, this answer posted on SO will help point you in the right direction:
How to make build definition in TFS Build 2010 configurable w.r.t input variable values and “items to build”