Matt RaibleMatt Raible is a Web Developer and Java Champion. Connect with him on LinkedIn.

The Angular Mini-Book The Angular Mini-Book is a guide to getting started with Angular. You'll learn how to develop a bare-bones application, test it, and deploy it. Then you'll move on to adding Bootstrap, Angular Material, continuous integration, and authentication.

Spring Boot is a popular framework for building REST APIs. You'll learn how to integrate Angular with Spring Boot and use security best practices like HTTPS and a content security policy.

For book updates, follow @angular_book on Twitter.

The JHipster Mini-Book The JHipster Mini-Book is a guide to getting started with hip technologies today: Angular, Bootstrap, and Spring Boot. All of these frameworks are wrapped up in an easy-to-use project called JHipster.

This book shows you how to build an app with JHipster, and guides you through the plethora of tools, techniques and options you can use. Furthermore, it explains the UI and API building blocks so you understand the underpinnings of your great application.

For book updates, follow @jhipster-book on Twitter.

10+ YEARS


Over 10 years ago, I wrote my first blog post. Since then, I've authored books, had kids, traveled the world, found Trish and blogged about it all.

CruiseControl and Maven

At work today, I put together a config.xml for CruiseControl to run continuous integration builds for our project. We're using Maven, so I used the CruiseControl Plugin to generate a cruisecontrol.xml file to get started. Then I moved this file up a few directories, renamed it to config.xml and changed all the log paths to be outside of the project.

There's quite a difference between running CruiseControl with Ant vs. Maven. With Ant - you tend to delete the whole project, check it out from CVS and build/test it from scratch. With Maven, the recommendation seems to be a bit different. What I found on the mailing lists and such was that you should manually checkout your project into your "checkout" directory and then call "scm:update-project|clean test" from config.xml. With Maven, it seems there's no CruiseControl-specific maven.xml file for your project.

I tend to like the delete/checkout/test approach you get with Ant over the update/test approach with Maven. For those of you that are using CruiseControl with Maven - is it possible to do delete/checkout/test - or am I stuck with the update/test approach?

Posted in Java at Jan 10 2005, 10:34:09 PM MST 3 Comments
Comments:

Quote:
is it possible to do delete/checkout/test - or am I stuck with the update/test approach?
Yes, it surely is possible! I'm doing it by having a project.xml and maven.xml in the cruisecontrol directory. The maven.xml contains a special goal, ci-build, that does the checkout (via ant):
<project xmlns:ant="jelly:ant" xmlns:m="jelly:maven">
  <goal name="ci-build">
    <ant:ant dir="${basedir}" antfile="ant.xml" target="checkout"/>
      <!-- run the build targets, site-deploy, .... -->
   </goal>
</project>
ant.xml then contains the target "checkout":
  
<target name="checkout" description="Update packages from CVS and build with maven">
  <delete dir="checkout/m2n-im"/>
  <cvs command="co m2n-im" cvsroot="${cvs.repository}" quiet="true" dest="checkout"/>
</target>
I call maven with target "ci-build" from cruise's config.xml. But now that i've read how it is supposed to work, i'm thinking about changing my setup to be more like the one you described. I'm thinking about setting it up so that only altered subprojects have to be re-built, not the whole project (currently ~20 minutes for a full build - sucks big time), plus maybe a nightly build that deletes and checks out instead of updating.

Posted by Wolfgang Groiss on January 11, 2005 at 01:33 AM MST #

I haven't used CruiseControl but you can checkout a clean copy of a project with scm:checkout-project and run some goals in the checked out project setting maven.scm.bootstrap.goals. More info at the plugin page

Posted by Carlos Sanchez on January 11, 2005 at 08:22 AM MST #

why do you want to checkout the whole thing again? Its actually nice to update only, lots better for your network. You need to look at how you or the tool update, and do so you get a clean copy of the repository.

Posted by jean-pierre sevigny on November 18, 2006 at 07:35 PM MST #

Post a Comment:
  • HTML Syntax: Allowed