Title: Message
I found something which almost works. I'll share what I found with everyone.
 
 
------------------------------  <paste from old message> ----------------------------------------------------------------

Michael,

I didn't have to depend on environmental variables, but they are easy to use - check out the <sysinfo/> task.

Here's my code:

------------------- snip ---------------------------------------------

<readregistry

property="pathToVS"

hive="LocalMachine"

key="SOFTWARE\Microsoft\VisualStudio\7.1\InstallDir" />

<exec

program="${pathToVS}devenv.exe"

commandline="/build ${project.config} ${nant.project.basedir}\${nant.project.name}.sln" workingdir="${nant.project.basedir}" />

------------------- end -----------------------------------------------

I have ${project.config} set to either "Debug" or "Release". I really should expand this and detect the framework version so that I can pass "7.0" or "7.1" to the "readregistry" task, but I haven't gotten around to it yet.

I should point out that I had trouble with this. Something about this was corrupting my SourceSafe config files (*.vspscc, *.vssscc, etc) in some strange way where I couldn't compile the project in Visual Studio after successfully compiling from my NAnt script. I've stopped using the NAnt build script to compile because I don't have time to figure out what's wrong. I suspect that if I check out from VSS to some other directory and compile there instead of compiling the same source files from both console mode and GUI tools, everything will be fine. If you don't use VSS, you might not have the same problem.

By the way, I got this from the source code to a Microsoft build tool I found at: http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=2cb20e79-d706-4706-9ea0-26188257ee7d. It has some good features, but not enough to beat NAnt. The <solution> task was worth pirating, that's how I got to this point.

Kevin

 

 

-----Original Message-----

From: Dang, Michael (PSG IT - Houston) [mailto:[EMAIL PROTECTED]]

Sent: Tuesday, August 05, 2003 3:33 PM

To: Williams, Kevin

Subject: RE: [Nant-users] Solution task fails for ASP.NET project

 

Kevin,

Question how did u get your VS.net environment variables loaded when you ran the <exec> task.

My <exec> task looks like this but it give me an error that it cannot find the devenv.exe

<exec program="devenv" commandline="${buildsrccode.dir}\MySolution.sln"

/>

do u have a sample of your <exec> task that you can share?

Many Thanks,

Michael Dang

-----Original Message-----

From: Williams, Kevin [mailto:[EMAIL PROTECTED]]

Sent: Tuesday, August 05, 2003 2:37 PM

To: Dang, Michael (PSG IT - Houston)

Subject: RE: [Nant-users] Solution task fails for ASP.NET project

Michael,

No, I didn't. I changed my script to directly call devenv.exe with command-line arguments to build the solution.

Kevin

 

-----Original Message-----

From: Dang, Michael (PSG IT - Houston) [mailto:[EMAIL PROTECTED]]

Sent: Tuesday, August 05, 2003 1:27 PM

To: [EMAIL PROTECTED]

Subject: [Nant-users] Solution task fails for ASP.NET project

 

Hi Kevin,

Did you ever figure out how to overcome this?

403 (Forbidden) error when the solution task attempts to retrieve the *.csproj file for the ASP.NET project Michael Dang

------------------------------  </paste from old message> ----------------------------------------------------------------
-----Original Message-----
From: Yair Levy [mailto:[EMAIL PROTECTED]
Sent: Wednesday, August 20, 2003 4:18 AM
To: [EMAIL PROTECTED]
Subject: [Nant-users] Solution task fails for ASP.NET project

hi kevi
i have the same problem, did u got any help?
if you did can you help me too?

Reply via email to