---
title: "Invoking FinalBuilder from TFS/MSBuild"
url: "https://courses.osherove.com/courses/automating-all-the-things-with-finalbuilder/invoking-finalbuilder-from-tfs-msbuild.md"
canonical: "https://courses.osherove.com/courses/automating-all-the-things-with-finalbuilder/invoking-finalbuilder-from-tfs-msbuild/"
tags: []
author: "Roy Osherove"
description: "Lesson 17 of 18 in Automating All the Things with FinalBuilder (Orchestrating FinalBuilder with a CI System), 1:22. Free video by Roy Osherove."
usage: "Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page)."
license: "https://creativecommons.org/licenses/by/4.0/"
---

# Invoking FinalBuilder from TFS/MSBuild

1. [Courses](https://courses.osherove.com/#courses)
2. [Automating All the Things with FinalBuilder](https://courses.osherove.com/courses/automating-all-the-things-with-finalbuilder/)
3. Orchestrating FinalBuilder with a CI System

Lesson 17 of 18

Duration: 1:22 [Watch on YouTube](https://www.youtube.com/watch?v=0yAKwBs7YHY)

## In this lesson

Roy Osherove shows the example that comes with [FinalBuilder](https://osherove.com/blog/2005/3/12/cooltool-finalbuilder-30-the-ultimate-build-management-and-a.html "[CoolTool] FinalBuilder 3.0 - the ultimate build management and automation tool (osherove.com)") for running it from MSBuild or TFS: an MSBuild project file uses a task from a DLL included with FinalBuilder to invoke FBCmd.exe with the path of the project file, and can set more properties such as variables. Environment variables are also included in the project by default, so more settings can be passed that way.

## Transcript

202 words

[\[00:02\]](https://www.youtube.com/watch?v=0yAKwBs7YHY&t=2s) If you're wondering if you can run FinalBuilder from MSBuild or TFS or other things like that, yes, you definitely can. In fact, as part of the examples coming with FinalBuilder, there is an XML file called MSBuild project which calls FB.proj. And in there, there's a simple example that shows how you have a task that's already in a DLL that's that's included with FinalBuilder. So you need this DLL to be wherever the server that will invoke it is and you need to have a using task called FinalBuilder.fbc cmd.

[\[00:37\]](https://www.youtube.com/watch?v=0yAKwBs7YHY&t=37s) So this will be actually executing the project with a target name called build and this is the message that will be displayed and then we basically invoke the fbcmd target which means that we invoke fbcmd.exe exe and this is the path to the project file we want to invoke. And here we can even set more properties to FinalBuilder project including settings, variable names or anything like that.

[\[01:09\]](https://www.youtube.com/watch?v=0yAKwBs7YHY&t=69s) If we want to pass more settings, we can also use environment variables which will be included by default in our project. So it should be very easy to integrate calling FinalBuilder from TFS or any other MSBuild related task.

## Related

- [The difference between continuous Integration tools and automated build tools](https://osherove.com/blog/2010/1/14/the-difference-between-continuous-integration-tools-and-auto.html) · osherove.com

    Roy's post separating build automation tools such as MSBuild and FinalBuilder from CI tools such as the Team System build server, which invokes MSBuild files, and on letting the CI tool trigger a FinalBuilder script.

- [Use Version Aware Build Scripts](https://pipelinedriven.org/article/2014/3/2/use-version-aware-build-scripts) · pipelinedriven.org

    Roy's argument for using CI servers as dumb triggers of a build script kept in source control, such as a FinalBuilder project, which is what the MSBuild task here starts.

### Also linked in this lesson

#### osherove.com

- [\[CoolTool\] FinalBuilder 3.0 - the ultimate build management and automation tool](https://osherove.com/blog/2005/3/12/cooltool-finalbuilder-30-the-ultimate-build-management-and-a.html)

[Previous lesson Custom Action Scripts in Powershell & Javascript](https://courses.osherove.com/courses/automating-all-the-things-with-finalbuilder/custom-action-scripts-in-powershell-and-javascript/) [Next lesson Invoking FinalBuilder From TeamCity](https://courses.osherove.com/courses/automating-all-the-things-with-finalbuilder/invoking-finalbuilder-from-teamcity/)


---

## About the author

**Roy Osherove**: Senior Solutions Architect at AWS working on AI for production and AI-driven development; author of The Art of Unit Testing and Elastic Leadership, with about 20 years of consulting and training on unit testing, TDD, team leadership and continuous delivery.

### Sites

- [RobotPaper](https://robotpaper.ai/): This blog: AI patterns and anti-patterns, AI and coding agents, and engineering leadership.
- [osherove.com](https://osherove.com): Roy's personal site. Author of The Art of Unit Testing and Elastic Leadership; consulting and training on unit testing, TDD, team leadership and continuous delivery, plus about 20 years of blog posts.
- [The Art of Unit Testing](https://www.artofunittesting.com): The Art of Unit Testing, 3rd Edition (Manning): readable, maintainable, trustworthy unit tests, plus TDD workshops in C#, JavaScript, Java and Kotlin.
- [5whys.com](https://www.5whys.com): Roy's writing on software team leadership: self-organizing teams, surviving chaos, learning mode and the Elastic Leadership model.
- [Pipeline Driven](https://pipelinedriven.org): Continuous delivery and DevOps practices: build patterns, pipeline-friendly testing, DevOps metrics and enterprise DevOps.
- [Elastic Leadership](https://www.elasticleadership.com): Elastic Leadership, Roy's framework for software team leaders (survival, learning and self-organizing modes).

### Social

- X: https://x.com/royosherove
- LinkedIn: https://www.linkedin.com/in/osherove/

### Contact

- Contact form: https://forms.gle/jQSx5KoXvrVA1JCK7

### License

Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page). License: https://creativecommons.org/licenses/by/4.0/
