V1TFS links VersionOne Workitems to TFS Check-ins and Builds.
We want developers to be able to run the build script before Jenkins, so they can know if it will work with it. From time-to-time there are environment differences (like with NuGet) that get in the way, but that is the main idea.
Developers should be able to build from Visual Studio too. This means that some extra packages could be installed so it works there too.
Install NuGet 2.7 or greater.
We use NuGet to manage external dependencies that this project requires. -- Most importantly, as of NuGet 2.7, there is a simplified package restore workflow for NuGet packages that this code requires via packages.config
files in each project. See this post for all the details.
We build with Visual Studio 2012 Professional and Premium, and several other tools, all of which are listed in the Chocolatey packages.config file.
Not familiar with Chocolatey? It's a package manager for Windows, similar to apt-get in the Linux world. It actually uses NuGet internally. To installl Chocolatey:
- First, see Chocolatey's requirements
- Next, assuming you already Cloned or Downloaded this repository from GitHub into
C:\Projects\V1TFS
, open anAdmininstrator
command prompt in that folder and runinstall_chocolatey.bat
If the Chocolatey install worked, then:
- First: if you already have Visual Studio 2012 installed without using Chocolatey, you can open up packages.config and remove the line for it. That will avoid downloading the large file over the internet. The same applies for any other package.
- Close the command prompt and open a new
Administrator
command prompt so that you get an updated PATH environment variable and navigate back to the repository folder. - Run
install_dev_tools.bat
This should start downloading and automatically installling the tools listed in packages.config.
- Install Visual Studio 2012 Professional or higher
- Install Update 4 for Visual Studio 2012
- Install Visual Studio 2012 SDK -- includes project templates, tools, tests, and reference assemblies that are required to build extensions for Visual Studio 2012
- Install Bash shell -- our
build.sh
and other scripts are written in Bash, so you need a good Bash shell to execute them. People on the VersionOne team use both [http://git-scm.com/download/win](Git Bash) and Cygwin with the Bash package successfully. - Install WiX Toolset, which is open-source software
Assuming you have followed the previous steps and your environment is all setup correctly now:
- Open a Git Bash prompt as
Administrator
- Change directory to
C:\Projects\V1TFS
- Type
./build.sh
This should build all successfully.