Correct me if i am wrong, you want the following:
1. The user creates a skeleton app with the geotools maven archetype.
2. The user builds there app with maven creating a jar file
3. The user drops the jar file into the same directory containing all
the gt2-*.jar files from a binary geotools release.
4. The user runs their app with java from the command line:
java -jar myapp.jar -classpath "<geotools libraries>"
Adrian Custer wrote:
> On Wed, 2006-10-25 at 10:12 -0700, Justin Deoliveira wrote:
>> >From what I can tell, the finalName does not affect what gets installed
>> in the repository. Only what the "built artifacts" are called ( jars
>> under the target directory). So if I am correct this only affects the
>> release artifacts, ie gt2-bin.zip will contain jars of the form gt2-*.jar.
>> But when the jars get deployed to a remote maven repository they will
>> not have the gt2 prefix, so in your archetype you can have the "users
>> pom" ( ie. the pom.xml in
>> maven/archetype/src/main/resources/archetype-resources ) depend on the
>> artifactId as normal ( no gt2 prefix ).
> Yes, that's correct. Only then i can't *run* the file by placing it in a
> directory with all the other jars in the gt-bin.zip! That's the issue. I
> could probably get the thing to run using mvn exec:java since that would
> grab the artifacts from the repository but I can't run using java -jar
> which seems a lot easier for newcomers.
>> I agree, it is confusing, I hope that made sense and didn't confuse you
>> more so then you were before :)
>> Adrian Custer wrote:
>>> Hey all,
>>> Could whoever designed this please explain what's going on? It seems to
>>> break thing because the name in the local maven repo used during the
>>> build differs from the name of the jars that will be used to run.
>>> In the archetype, I create a pom that is used to build the app, i.e.
>>> not maven/archetype/pom.xml which is used to create the archetype (and
>>> has almost on info since it depends only on maven). In the former
>>> pom.xml, I have to define the dependency used to build the userApp.
>>> Those artifacts will get pulled from the repository so must be *without*
>>> the leading 'gt-'. However, the dependencies I define also get used to
>>> build the classpath for the userApp but the classpath names will need
>>> the leading 'gt-'
>>> I admit my head hurts trying to understand poms, building directories
>>> with poms used to build jars, used run apps. Still, I think there is a
>>> non-trivial problem with the use of <finalName>gt-...
>>> Using Tomcat but need to do more? Need to support web services, security?
>>> Get stuff done quickly with pre-integrated technology to make your job easier
>>> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
>>> Geotools-devel mailing list
The Open Planning Project