Re: How to install library into repository?

2007-05-21 Thread jesseliu
You should install(deploy) the jar file into your company repository which 
is shared with your team. 
maven deploy command line seems like:(assuming on Windows OS)
mvn deploy:deploy-file -DgroupId=com.toedter.calendar
 -DartifactId=jcalendar -Dversion=1.3.2 -Dpackaging=jar -
Dfile=c:\path\to\jar\jcalendar-1.3.2.jar -Durl=\\192.168.1.10
\path\to\company\repository

In case your team member add the company repository to the maven config 
file, maven can automatically download the jcalendar-1.3.2.jar into local 
repository from company repository.




On Mon, 21 May 2007 16:30:26 +0200, Jansen Werner wrote
 Hi everybody,
 
 we would like to use jcalendar (http://www.toedter.com/en/jcalendar/)
  in our project. But it isn't available from the central repository.
 
 Maven suggests adding it to the local repository:
 
 Then, install it using the command: 
 mvn install:install-file -DgroupId=com.toedter.calendar
 -DartifactId=jcalendar \
 -Dversion=1.3.2 -Dpackaging=jar -Dfile=jcalendar-1.3.2.jar
 
 But I don't want to install it in every developer's local repository.
 How can I add this library to our site-local repository in a maven way?
 
 Regards,
 
 Werner
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


--
Powered By Open WebMail Project (http://openwebmail.org)


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



How to deploy source jar generated by source plug-in into repository when running mvn deploy?

2007-05-08 Thread JesseLiu
Hi,all
How to deploy source jar generated by source plug-in into repository when 
running mvn deploy?

Exclude some classes when package a jar.

2007-04-11 Thread JesseLiu
All,
I have a jar project.  When packaging,  I want  some specified class excuded 
from the jar file. How should I do ?

Thanks for any suggestions!

How to use JunitEE in M2?

2007-03-20 Thread JesseLiu
Hi there,
I have not found a plugin for JunitEE, Is there any plugin for JUnitEE? Can 
anyone give me a sample pom.xml?

Thanks


Jesse

How to make my own repository prior to central in settings.xml?

2007-03-15 Thread JesseLiu
Hi
I want maven2 first look up artifacts in my own repository , if not found ,then 
the central repository.
How should I config in the settings.xml

Thanks for any advise?

Jesse

Can Maven 2.X run offline?

2007-03-14 Thread JesseLiu


With Regards,
Jesse Liu
~~
Tel: 86-755-2699 5598
Email: [EMAIL PROTECTED]
Skype: liujiasong
MSN: [EMAIL PROTECTED]
~~

Re: Can Maven 2.X run offline?

2007-03-14 Thread JesseLiu
The case is that I want to build a file repository in LAN which can't connect 
to Internet.
so,In pom.xml it seems like below:
project
  modelVersion4.0.0/modelVersion
  groupIdcom.mycompany.dolly/groupId
  artifactIdsample/artifactId
  version1.0.1/version
  dependencies/
  repositories
repository
  idcentral/id
  nameMaven Repository Switchboard/name
  layoutdefault/layout
  url file://e:\repository1 /url
/repository
   /repositories
/project

The localRepository is default to ~/.m2/ which has no artifacts from the 
beginning. but I am sure that the specified central repository 
file://e:\repository1 has all the required artifacts, because it is copied from 
another runnable maven localRepository.

The mvn result is :
E:\mvndemo\my-appmvn -o compile
[INFO]
NOTE: Maven is executing in offline mode. Any artifacts not already in your 
local
repository will be inaccessible.

[INFO] Scanning for projects...
[INFO] -
---
[INFO] Building Unnamed - com.mycompany.dolly:sample:jar:1.0.1
[INFO]task-segment: [compile]
[INFO] -
---
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] The plugin 'org.apache.maven.plugins:maven-resources-plugin' does not 
exist or no valid version could be found
[INFO] 
[INFO] For more information, run Maven with the -e switch
[INFO] 
[INFO] Total time:  1 second
[INFO] Finished at: Wed Mar 14 18:35:39 CST 2007
[INFO] Final Memory: 1M/2M
[INFO] 


Thanks for any suggestion?




- Original Message - 
From: Markku Saarela [EMAIL PROTECTED]
To: Maven Users List users@maven.apache.org
Sent: Wednesday, March 14, 2007 6:09 PM
Subject: Re: Can Maven 2.X run offline?


 Yes. Use -o command line argument.
 
 - markku
 
 JesseLiu wrote:
  With Regards,
  Jesse Liu
  ~~
  Tel: 86-755-2699 5598
  Email: [EMAIL PROTECTED]
  Skype: liujiasong
  MSN: [EMAIL PROTECTED]
  ~~
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

How to Use custom central repository completely instead of the default central repository?

2007-03-14 Thread JesseLiu
I want to build a file repository in my computer which can't access Internet.
so, I create the repository in  file://e:\repository1 which contains all the 
required artifacts hierarchy. and config pom.xml like below:
project
  modelVersion4.0.0/modelVersion
  groupIdcom.mycompany.dolly/groupId
  artifactIdsample/artifactId
  version1.0.1/version
  dependencies/
  repositories
repository
  idcentral/id
  nameMaven Repository Switchboard/name
  layoutdefault/layout
  url file://e:\repository1 /url
/repository
   /repositories
/project

The localRepository of Maven2 is default to ~/.m2/ which has no artifacts at 
the beginning. The mvn result is :
E:\mvndemo\my-appmvn -o compile
[ERROR] BUILD ERROR
[INFO] 
[INFO] The plugin 'org.apache.maven.plugins:maven-resources-plugin' does not 
exist or no valid version could be found
[INFO] 

According log, mvn2 try to access http://repo1.maven.org/maven2 ( not 
file://e:\repository1 ) to download the maven-resources-plugin. 
How can my own repository completely replace the dafault repository  
http://repo1.maven.org/maven2.

Thanks for any suggestion?


Re: Generics and java version.

2007-03-14 Thread JesseLiu
add the following block to your pom.xml
  
project

build

plugins
 plugin
 groupIdorg.apache.maven.plugins/groupId
 artifactIdmaven-compiler-plugin/artifactId
 configuration
 source1.5/source
 target1.5/target
 /configuration
  /plugin
/plugins
/build
/project



JesseLiu
- Original Message - 
From: Owen Thomas [EMAIL PROTECTED]
To: users@maven.apache.org
Sent: Thursday, March 15, 2007 1:48 PM
Subject: Generics and java version.


Hello.

 

Still new to Maven, I'm trying to port a project from Ant to Maven, and get the 
following error...

 

H:\CurrentProjects\JVMHost\src\main\java\au\net\wcg\jvmhost\CommandReturn.java:[18,18]
 generics are not supported in -source 1.3

[INFO](try -source 1.5 to enable generics)

I found this reference: 
http://forum.springframework.org/showthread.php?t=24913, but it talks of 
changing my parent POM. I can still count the number of times I can count the 
times I've used Maven on one hand, and I am yet to receive enlightenment 
vis-à-vis the nature of the POM.

 

How do I get maven to compile my project under 1.5? If anyone uses Mavenide for 
NetBeans, knowing of a NB specific way of doing this would be great too.

 

Your help is greatly appreciated,

 

  Owen.