Automating VS2005 builds

2

2b|!2b==?

I am working on a largish project (about 40 modules). I have created a
solution that builds all 40 modules/projects. However, I want to be able
to automate the build process - and kick it off without having to start
the IDE etc.

I fiddled around with NAnt for a while but it seems VC8 dosent work so
well with NAnt (from what I read + my own experience). Bottom line, I
don't have to much time to waste trying to fiddle with NAnt et all, I
have resorted to writing a batchfile to just get things done quickly.

Does anyone know if VS2005 can be automated like this?

If yes - can you do the ff:

1). log errors/warnings/build progress etc?
2). Get an errorlevel/return code so one can act appropriately wjhen the
build breaks ?

Anyone has some experience/tips doing this?
 
N

Nathan Mates

1). log errors/warnings/build progress etc?

This works great from a batch script:

"C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv" tools.sln /build "Debug" /out d:\tools_core_debug_output.txt
2). Get an errorlevel/return code so one can act appropriately wjhen the
build breaks ?

Parse the output text file yourself. Not all that hard.

Nathan Mates
 
2

2b|!2b==?

Nathan said:
This works great from a batch script:

"C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv" tools.sln /build "Debug" /out d:\tools_core_debug_output.txt




Parse the output text file yourself. Not all that hard.

Nathan Mates

Thanks - I'm not so sure about parsing the log file though - surely it
(devenv)MUST return some number after running ?
 
N

Nathan Mates

Thanks - I'm not so sure about parsing the log file though - surely it
(devenv)MUST return some number after running ?

Why not test this yourself? Make a 'hello, world' project, run a
cmdline build. Add a syntax error. Run again. Note the return
value. That would likely be faster than posting to usenet.

Nathan Mates
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top