<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>BlackBox : Tag scala</title>
    <link>http://www.warneronstine.com/blog/articles/tag/scala</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Where technology and art disappear</description>
    <item>
      <title>Is Maven going away?</title>
      <description>&lt;p&gt;First, let me say, I like &lt;a href="http://maven.apache.org"&gt;Maven&lt;/a&gt; - a lot. I&amp;#8217;ve liked the idea, if not the execution, since 1.0 (yes, I know there is some serious bad blood for the implementation of 1.0, and yes I still liked it). But I&amp;#8217;ve recently run into some irritating problems with Maven that would again, I think, require a major reworking of what it does.&lt;/p&gt;

&lt;p&gt;Here is the main issue Maven is designed to handle one language only for its compilation - primarily Java. This is rapidly starting to fall apart now that the JVM has some serious contenders besides Java, namely &lt;a href="http://groovy.apache.org"&gt;Groovy&lt;/a&gt;, &lt;a href="http://jruby.codehaus.org/"&gt;JRuby&lt;/a&gt;, &lt;a href="http://www.jython.org/"&gt;Jython&lt;/a&gt;, and &lt;a href="http://www.scala-lang.org/"&gt;Scala&lt;/a&gt;. There are some hackish things for getting Maven to deal with these, however it still only has one &amp;#8220;true&amp;#8221; source directory for compilation. A case in point is a mixed Java/Groovy project - trying to get &lt;a href="http://www.jetbrains.com/idea/"&gt;IntelliJ&lt;/a&gt; to respect the fact that I want not one, but two main source directories is a pain in the ass as I have to either tell it not to sync everytime I launch or I have to refix the source directories each time I update the project. &lt;/p&gt;

&lt;p&gt;This is what triggered this post - what happens when I want to do some &lt;a href="http://labs.adobe.com/technologies/flex/"&gt;Flex&lt;/a&gt; programming with some Java, ActionScript and MXML, all of these are true source files (and in Maven specfic directories). I&amp;#8217;m sure some Mavenite is going to say that these should be separate projects, but in alot of cases they aren&amp;#8217;t and it doesn&amp;#8217;t make sense to actually separate them into sub-projects. And I&amp;#8217;m equally as sure that some Ant-ite is going to come along and tell me to use &lt;a href="http://ant.apache.org/"&gt;Ant&lt;/a&gt; - I won&amp;#8217;t. Ant is stuck in the past and I won&amp;#8217;t use it unless I absolutely have to. I like the &amp;#8220;imposed&amp;#8221; structure that Maven offers. I can walk up to any project and know where  to find stuff instead of blindly hunting around for hours trying to piece it together like some giant source-code jigsaw puzzle, blech.&lt;/p&gt;

&lt;p&gt;So, I&amp;#8217;m at cross-roads, what should I do? There is &lt;a href="http://ant.apache.org/ivy/"&gt;Ivy&lt;/a&gt; (for dependency management -which they got from Maven natch), but that requires Ant, blech. There&amp;#8217;s also &lt;a href="http://gant.codehaus.org/"&gt;Gant&lt;/a&gt;, ok, this is better, but still Ant. &lt;a href="http://groovy.codehaus.org/GMaven"&gt;GMaven&lt;/a&gt;, but I&amp;#8217;m right back where I started.&lt;/p&gt;

&lt;p&gt;Enter, &lt;a href="http://www.gradle.org/"&gt;Gradle&lt;/a&gt;, a new Groovy-based build system that offers alot of the benefits of Maven without locking you in and the flexibility of Ant. I&amp;#8217;m not 100% sold on it yet, but I&amp;#8217;m going to give it a shot for a relatively complex project that will have a fair amount of Java, Groovy and other fun resource files. It looks interesting in that all the build files are actually Groovy scripts that are a DSL (like Gant files). Here&amp;#8217;s a short example with some dependencies (taken directly from their examples in the download).&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;import org.gradle.api.tasks.util.FileSet

usePlugin('groovy')

group = 'org.gradle'
version = '1.0'

sourceCompatibility = 1.5
targetCompatibility = 1.5

dependencies {
   clientModule(['groovy'], ":groovy-all:1.6-beta-1") {
       dependency(":commons-cli:1.0")
   }
   compile project(':groovycDetector')
   testCompile ":junit:4.4"
}

compile {
   exclude('**/Exclude.java')
   groovyExclude('**/ExcludeGroovy.groovy')
   groovyJavaExclude('**/ExcludeGroovyJava.java')
}

manifest.mainAttributes(myprop: 'myvalue')
metaInf &amp;lt;&amp;lt; new FileSet(new File(srcRoot, 'metaInfFiles'))

test.options.systemProperties['org.gradle.integtest.buildDir'] = buildDir.absolutePath
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I will try and keep everyone up to date as I continue to investigate this new build system. They also state that they are going to be supporting polyglot programming in the near future which I&amp;#8217;m looking forward to.&lt;/p&gt;</description>
      <pubDate>Sun, 06 Jul 2008 07:49:33 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:f693853e-5003-4e42-bab5-7bf1838bfc9f</guid>
      <author>Warner Onstine</author>
      <link>http://www.warneronstine.com/blog/articles/2008/07/06/is-maven-going-away</link>
      <category>programming</category>
      <category>maven</category>
      <category>java</category>
      <category>groovy</category>
      <category>scala</category>
      <category>polyglot</category>
      <trackback:ping>http://www.warneronstine.com/blog/articles/trackback/321</trackback:ping>
    </item>
  </channel>
</rss>
