Another bad day with Maven ... first, something changed in the Maven Archetype plugin, so now my archetypes don't work anymore ... and I'm far from the only person with this problem.
Second, I thought I'd use mvn eclipse:eclipse
instead of my Ruby script to keep my Eclipse .classpath file up to date: but it doesn't seem to want to download and connect the Tapestry Java sources. So back to the script it is.
Honestly, howard. Stop using mvn eclipse:eclipse. In fact, stop using .classpath/.project on a maven project. Use the latest m2eclipse and let it keep your project in sync with the maven metadata. It maintains the classpath in an internal container derived directly from your dependencies, not via a brittle sync process.
ReplyDeleteAs to the archetype process, they screwed that puppy up, didn't they.
I thought you were planning to wean Tapestry off Maven Howard? Are you too invested in it now, or have you changed your mind?
ReplyDeleteWe stayed clear of Maven due to your unhappiness and intention to change and it does cause us problems occasionally because T5 uses Maven, but I hope that it's sparing us some of this kind of M2 pain. Although we do have some problems with Ivy, mostly it just works for dependency management.
Two things: from your google search the solution to the archetype seems to be to delete the local repository, secondly with eclipse:eclipse, there is an option to download sources which is by default disabled...
ReplyDeleteErik: good notes, but I found those and they didn't work; Deleting the repository did not resolve the archetype problem, and only some sources were downloaded.
ReplyDeleteThanks to Raphaël Piéroni the error was found: there was an extra <directory> element in my archetype-metadata.xml. This was not reported at all by Maven.
ReplyDeleteYou should convert:
<fileSet filtered="true" packaged="false">
<directory>src/test/resources</directory>
<directory>src/test/conf</directory>
</fileSet>
to:
<fileSet filtered="true" packaged="false">
<directory>src/test/resources</directory>
</fileSet>
<fileSet filtered="true" packaged="false">
<directory>src/test/conf</directory>
</fileSet>
Future versions of the archetype plugin will report the first error, rather than ignore it leading to the second incomprehensible error (I received).
Meanwhile, this has spurred me to locate a new tool even more strongly than before, and right now Buildr looks like the right approach (there's also Gradle, Savant and probably others).
I've always been put off using maven for individual projects. I don't like the idea of having to debug yet another framework when something i dont quite understand goes wrong. I'm happy enough downloading binaries/sources when i need to or want to upgrade (generally infrequently) and the pain of doing so manually is absolutely minimal.
ReplyDeleteI seem to be alone here though since everyone else uses it. What am I missing out on?
"I don't like the idea of having to debug yet another framework", I used maven quite alot on many projects. I never had to debug it to understand what is going wrong. Howard uses cases are quite complex - I wouldn't generalize from his experience.
ReplyDeleteMaven helps you to introduce a good testing process in your projects and you configure the build instead of scripting it.
"Howard uses cases are quite complex - I wouldn't generalize from his experience."
ReplyDeleteHow do you know my use cases are any less complex, if not more?