Re: Using Spring 2.5.1 for Spring-dao and Spring-hibernate3
Hi Jacob, Read the on-line book here to understand maven coordination: http://www.sonatype.com/book/simple-project.html#maven_coordinates and then check the maven 2 repository here with your browser to find what artifacts or which specific versions are available: http://repo1.maven.org/maven2/org/springframework/ Hope it helps. Best Regards Fred Zhang -邮件原件- 发件人: Jacob Bergoo [mailto:[EMAIL PROTECTED] 发送时间: 2008年1月29日 8:09 收件人: users@maven.apache.org 主题: Using Spring 2.5.1 for Spring-dao and Spring-hibernate3 Hi, I am beginner with maven and now I am trying to create a project that uses Tapestry 5, Spring 2.5.1, Hibernate 3, MySQL I have created a archtype for tapestry5 and added : org.springframework spring-web 2.5.1 this works fine and downloads spring-beans, spring-core,spring-context and spring-web to my local repository, but I want to use hibernate 3 with spring (I need the spring-dao, spring-hibernate3, spring-jdbc, spring-aop also) when I try to add this to my pom.xml It didn't find anything more to download org.springframework spring-dao 2.5.1 org.springframework spring-hibernate3 2.5.1 Am I doing something wrong here? Thanks for any help Jacob -- View this message in context: http://www.nabble.com/Using-Spring-2.5.1-for-Spring-dao-and-Spring-hibernate3-tp15149196s177p15149196.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
答复: how to use maven project properties in other configuration files?
Kalle, Thanks a lot! -邮件原件- 发件人: Kalle Korhonen [mailto:[EMAIL PROTECTED] 发送时间: 2008年1月7日 11:47 收件人: Maven Users List 主题: Re: how to use maven project properties in other configuration files? On 1/6/08, Fred Zhang <[EMAIL PROTECTED]> wrote: > > My project is a multi-module project which contains an ear module and a > war module. I need to access the property of the ear module (for the ear > name and version) from the war module or from the project root pom. > Is that possible to access properties of a module from another module or > from the project root pom in maven? > No, but the properties declared in the parent pom ( http://maven.apache.org/pom.html#Properties) are available in the child modules, so you'd need to organize your project so that the parent is driving setting the properties and both ear and war are using them. Kalle -Original message--- > From: Kalle Korhonen [mailto:[EMAIL PROTECTED] > Sent: Jan.04.2008 16:31 > To: Maven Users List > Subject: Re: how to use maven project properties in other configuration > files? > > Make your configuration file a filtered resource: > > http://maven.apache.org/plugins/maven-resources-plugin/examples/filter.html > > Kalle > > On 1/3/08, Fred Zhang <[EMAIL PROTECTED]> wrote: > > > > Hi there, > > Sometimes I need to use maven project properties, e.g. ${project.version > } > > etc in some configuration files (not pom.xml or settings.xml). For > > example, when I build an ear file with the name "EAR-${project.version > }.ear", > > I need to use this ear name in some configuration file for JNDI-lookup. > > > > But how can I use the maven property ${project.version} in configuration > > files? Is there any plug-in that can make the job done? > > > > Thanks in advance! > > > > Fred Zhang > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: how to use maven project properties in other configuration files?
Thanks Kalle! My project is a multi-module project which contains an ear module and a war module. I need to access the property of the ear module (for the ear name and version) from the war module or from the project root pom. Is that possible to access properties of a module from another module or from the project root pom in maven? Best Regards Fred Zhang -Original message--- From: Kalle Korhonen [mailto:[EMAIL PROTECTED] Sent: Jan.04.2008 16:31 To: Maven Users List Subject: Re: how to use maven project properties in other configuration files? Make your configuration file a filtered resource: http://maven.apache.org/plugins/maven-resources-plugin/examples/filter.html Kalle On 1/3/08, Fred Zhang <[EMAIL PROTECTED]> wrote: > > Hi there, > Sometimes I need to use maven project properties, e.g. ${project.version} > etc in some configuration files (not pom.xml or settings.xml). For > example, when I build an ear file with the name "EAR-${project.version}.ear", > I need to use this ear name in some configuration file for JNDI-lookup. > > But how can I use the maven property ${project.version} in configuration > files? Is there any plug-in that can make the job done? > > Thanks in advance! > > Fred Zhang > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
how to use maven project properties in other configuration files?
Hi there, Sometimes I need to use maven project properties, e.g. ${project.version} etc in some configuration files (not pom.xml or settings.xml). For example, when I build an ear file with the name "EAR-${project.version}.ear", I need to use this ear name in some configuration file for JNDI-lookup. But how can I use the maven property ${project.version} in configuration files? Is there any plug-in that can make the job done? Thanks in advance! Fred Zhang - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
how to set subversion authentication information into settings.xml (instead of writing it into project pom)
Hi there, I'm working on configuring maven-scm plugin to use maven to do daily update/commit jobs. A problem is that I don't want to write my authentication information (username/password) into the project pom file (otherwise it will be shared through subversion). Neither want I use subversion "cached password" mechanism. I found some web-pages said that the svn repository server information (with username/password) could be written in settings.xml as following: http://svnrepo.my.com/svn/project/trunk username password And in project pom, just write scm:svn:http://svnrepo.my.com/svn/project/trunk http://svnrepo.my.com/svn/project/trunk Then the mvn scm:update should work. I tried. But I still got authentication failure. Is there any way to make it? Thanks in advance. Fred
答复: How does maven find the "real" central repository even when I overrided the "centra l" repository in my profile
Hi Wendy, Thanks a lot for the reponse! Regards Fred Zhang -邮件原件- 发件人: Wendy Smoak [mailto:[EMAIL PROTECTED] 发送时间: 2007年12月10日 10:11 收件人: Maven Users List 主题: Re: How does maven find the "real" central repository even when I overrided the "central" repository in my profile On Dec 9, 2007 6:36 PM, Fred Zhang <[EMAIL PROTECTED]> wrote: > Hi there, > > I set up a mirror of repo1.maven.org/maven2 for my group and added the > following profile to the settings.xml file. The key point here is that I > overrided the "central" repository with my mirror, so that the "maven"s using > this profile will go to myrepo instead of repo1.maven.org/maven2 to find > artifacts. > > It worked as expected: all the artifacts were downloaded from my mirror. And > I checked mvn help:effective-pom. The effective-pom was also as expected. > > But when I tried "archetype:create" goal, maven tried to connect the "real" > central (repo1.maven.org) and downloaded artifacts although some of those > artifacts were available in the mirror. > > Can anyone tell me how maven can find the "real" central repository even when > the original central in the SuperPOM is overrided in my profile? Unless there is a "project" (== a pom.xml in the current directory or specified with -f) Maven does not "see" your settings.xml file. You can use -DremoteRepositories=... to tell the Archetype plugin where to look. Also see the discussion here: http://jira.codehaus.org/browse/ARCHETYPE-59 -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How does maven find the "real" central repository even when I overrided the "central" repository in my profile
Hi there, I set up a mirror of repo1.maven.org/maven2 for my group and added the following profile to the settings.xml file. The key point here is that I overrided the "central" repository with my mirror, so that the "maven"s using this profile will go to myrepo instead of repo1.maven.org/maven2 to find artifacts. It worked as expected: all the artifacts were downloaded from my mirror. And I checked mvn help:effective-pom. The effective-pom was also as expected. But when I tried "archetype:create" goal, maven tried to connect the "real" central (repo1.maven.org) and downloaded artifacts although some of those artifacts were available in the mirror. Can anyone tell me how maven can find the "real" central repository even when the original central in the SuperPOM is overrided in my profile? Thanks! Here is my profile in "settings.xml": office central http://myrepo/mvncentral true true central http://myrepo/mvncentral false true