Open Source .NET Development [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Open Source .NET Development [Electronic resources] - نسخه متنی

Brian Nantz

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید


Draco.NET


Draco.NET (http://draconet.sourceforge.net), inspired by the Java CruiseControl Continuous Integration system, was the first .NET Continuous Integration system to appear (although under a different name). Because of this, Draco.NET is the most mature and easy to implement Integration system currently available.

NOTE

This is based on Draco.NET 1.5

Draco.NET supports the following SCM products:

  • CVS

  • Subversion

  • Visual Source Safe

  • Perforce

  • PVCS


Draco.NET supports building using NAnt or Visual Studio.NET and has a very intuitive and easily extendable pluggable architecture.

Installing


Installing Draco.NET is incredibly easy. The distribution contains a client and server MSI (Microsoft Installer) setup package that runs flawlessly.

Configuring


Listing 7.2 should look familiar since the Hippo.NET project was based upon this Draco.NET implementation.

Listing 7.2. Draco Server Configuration File

<draco xmlns="http://www.chive.com/draco">
<pollperiod>60</pollperiod>
<quietperiod>60</quietperiod>
<mailserver>mail.yourdomain.com</mailserver>
<fromaddress>you@yourdomain.com </fromaddress>
<builds>
<build>

<name>aspell-net</name>
<pollperiod>10</pollperiod>
<quietperiod>30</quietperiod>
<notification>
<email>
<recipient>you@yourdomain.com</recipient>
</email>
<file>
<dir>C:\book\BuildOutput</dir>
</file>
</notification>
<nant>
<buildfile>build\master.build</buildfile>
</nant>
<svn>
<url>file:///C:/book/svnrepository</url>
</svn>
<ignorechanges>
<ignore comment="autobuild"/>
</ignorechanges>
</build>
</builds>
</draco>

Listing 7.2 has the comments removed for sake of space, but the file is so well structured and commented that it is almost self-explanatory. The omitted comments are so good that you can literally cut and paste them into the configuration file and change the settings for your specific scenario. Note that this example uses Subversion (SVN) SCM. This build name (bolded in Listing 7.2) is very important because it will be in the notifications (like emails) and is used by the client to manually start a build.

TIP

James Geurts has recently released a Web-based log viewer for Draco.NET (http://blogs.biasecurities.com/jim).

A nice feature here is that you can use multiple notifications. This logs to an XML file (Listing 7.3) on the server and sends out an email (shown in Figure 7-3).

Listing 7.3. XML File Notification

<BuildResult xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org
/2001/XMLSchema-instance">
<Success>true</Success>
<BuildOutput>
...
</BuildOutput>
<Module>aspell-net</Module>
<BuildTime>2003-11-04T10:10:03.0391010-06:00</BuildTime>
<Modifications>
<Modification>
<Date>2003-11-04T09:30:36.1214920-06:00</Date>
<User>bnantz</User>
<Comment>initial import</Comment>
<Files>
<File>
<Type>Add</Type>
<Directory>\</Directory>
<File>aspell.net</File>
<Revision>1</Revision>
</File>
<File>
<Type>Add</Type>
<Directory>\</Directory>
<File>aspell-dev-0-50-3-3</File>
<Revision>1</Revision>
</File>
...
</Files>
</Modification>
</Modifications>
</BuildResult>

Figure 7-3. Draco.NET Email Notification.

[View full size image]

Running


Once the system is set up, any check-in like the one shown in Figure 7-4 will trigger a build.

Figure 7-4. Checking in to SVN Using Tortoise.

[View full size image]

Draco.NET builds can also be arbitrarily started or scheduled using the Draco.NET Command-Line Client (Figure 7-5).

Figure 7-5. Draco.NET Command-Line Client.

[View full size image]

Draco.NET server requires that the build tool (nant.exe) and the SCM tool (svn.exe) be in the path unless you change the build/nant/program config setting. If anything goes wrong, Draco.NET will either write to the Windows Event Log or to the Logfile in the C:\Program Files\Draco.NET Service folder.

TIP

Remember that .NET configuration files are only read upon starting the .NET executable, so when editing the configuration files, remember to restart the Draco.NET service.

Build System


Draco.NET now supports building without using NAnt. You can use the <solution> tag in the config file to point to the path of the solution you want to build. I am not sure, but I suspect this is based on the NAnt <solution> task. I think this because neither implementation supports Enterprise Template Projects.


    / 275