I am developing a large ASP.NET web app using Visual Studio 08, and I am new to build management (although I've tried nant and didn't like it for several reasons). I'm now trying out the finalbuilder trial, with the following questions:
1) Where should my build file reside? In the project's top directory?
2) What does "recursive" mean in VSS get latest version? As a programmer, I know recursive means to be calling a function from inside the same function, but in source control and scm, I am not sure. This is a generic source control question, so apologies for asking it here.
3) I want to integrate finalbuilder with CruiseControl.NET (although I'm interested in finalbuilder server). So would the ideal workflow be to check files in and then from CruiseControl.NET, I get the latest version - does getting the latest version mean checking out anyway? Of course I would write in the finalbuilder task to my cc config file.
Thanks for your post - I hope you'll come to love FinalBuilder! Here are some answers to your questions:
1) You can put your build project files anywhere you want, top directory included. One good approach is to have a folder like "Build" as a subdirectory of your main development directory. We also recommend checking your build process into source control, of couse!
2) "Recursive" for anything which works with files and directories means "Include subdirectories". So for VSS Get Latest it means "Don't just get this directory, but get all of the directories underneath."
3) If you're using VSS then you probably just want to Get Latest, not Check Out, because you're not going to change your source code as part of your build process. CruiseControl.NET can "Get Latest" automatically when it detects changes. If you need to change any files as part of your build process (like versioning, etc.), then you can use VSS actions inside the build project to check out and check back in.
Hopefully this answers your questions... please let us know how you go!
One question, how do I implement finalbuilder with Visual Studio 08? I mean, when I select build in Visual Studio, how does Visual Studio know to execute the build script (of which I've placed in my profject's root dir).
Also, I have added the finalbuilder task to my CCNET config file, but is there nothing I add to the build script?
The build script checks in the code, ccnetconfig gets the latest version at specific time intervals.
To answer your first question, FB isn't really designed as a replacement for the F6 key in Visual Studio. Under those circumstances, you probably just want to build your source files quickly using MSBuild, but not perform any other operations. If you really want to extend Visual Studio with FB, you can use the FBCmd MSBuild task (let me know if you'd like more information.)
To answer your second question, there shouldn't be anything you need to add to the FinalBuilder project. If you need to pass data from CC.NET, you can use an FBVariables section in the cc.net config file to pass in values. Does that answer your question?
Please do elaborate on the MSBuild thing you mentioned and how to set that up. Otherwise, how do I invoke the FinalBuilder build script?
My finalbuilder task is listed under the tasks element in the CCNET file like this:
C:\inetpub\wwwroot\Build\BuildScript.fbz5 6 false
3600 true
Syntax wise, is this fine?
This file sits in the project's root dir under a special directory called Build, and then there is another folder leading to the project files.
So the directory structure is: ProjectName > Build (1 folder) and Code(2nd folder > Code has all the code and stuff, Build contains this and the CCNET config file. Is this fine? I've read some things about how these files should be placed in their own dir with all the production code in a dir below it.
To answer your question about MSBuild, there is a FinalBuilder FBCmd task which can be used to include a FinalBuilder project as part of an MSBuild Project file (ie .csproj or .vbproj). However, I have to ask if you _really_ want FinalBuilder running each time you do a Debug build in Visual Studio - this will slow your development process down considerably, and I would recommend against it. I would save FinalBuilder for the "integration and release" stages of your build process - the point at which changes to source files are checked into source control.
If you want to do it, then csproj/vbproj files have extra Targets called BeforeBuild and AfterBuild. You can add an FBCmd task to one of these, which looks like this:
To answer your question about CC.NET, unfortunately your config file was mangled by the Forum software. To post XML content, use tags around the content you want to post. If that still doesn't work, you may want to consider attaching a text file. Sorry for the inconvenience.
I wont need to integrate FB into Visual Studio as invoking the build script from FB is a really simple task.
This thread and my other one have both run their courses as my build script compiles (well actually all I have to do is pass in some assemblies of my web app modules, which I will do soon. This is an Nunit issue anyway).