Re: Sharing reporting section across multiple modules

2009-08-11 Thread Kamlesh Sangani
As said these modules do not share the same parent. The reporting section is 
big 100 lines and I do not want to copy to 50 other files unless I have to.





From: David Hoffer dhoff...@gmail.com
To: Maven Users List users@maven.apache.org
Sent: Tuesday, August 11, 2009 12:05:29 PM
Subject: Re: Sharing reporting section across multiple modules

Put in parent pom.  That works for sure if you have a multi-module project.


-Dave

On Tue, Aug 11, 2009 at 12:55 PM, ksangani xkamle...@yahoo.com wrote:


 I have multiple maven modules for which I am generating site. For all
 modules
 reporting section is the same. Is there any way to share the reporting
 section across multiple modules without copying it? These modules are
 independent and do not share the same parent.

 I tried the following which does not work

 1. Create a profile in settings.xml for reporting and use that profile
 when building site. This does not work as profiles under settings.xml can
 not use reporting

 --
 View this message in context:
 http://www.nabble.com/Sharing-reporting-section-across-multiple-modules-tp24923662p24923662.html
 Sent from the Maven - Users mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org





  

Re: Environmental variable value for parent version tag?

2009-05-12 Thread Kamlesh Sangani
No this is not possible. version in parent can not use variable.




From: Thomas, Santhosh S santhosh.tho...@standardbank.co.za
To: users@maven.apache.org
Sent: Monday, May 11, 2009 10:26:06 AM
Subject: Environmental variable value for parent version tag?

Hi Maven users, 
Can I set environmental variable value for child pom's  parent
version tag? 
Something like below. 
In Child pom.. 
parent 
artifactIdartifact-parent/artifactId 
groupIdab.cd.ef/groupId 
version ${env.variable}/version !--Can I set environmental variable
here ? --
/parent 
If possible where should I declare the environmental variable? 
Thanks in advance 
Santhosh Thomas.

_

Standard Bank email Disclaimer and confidentiality note

This e-mail, its attachments and any rights attaching hereto are, unless the 
content clearly indicates otherwise, the property of 
Standard Bank Group Limited and its subsidiaries. It is confidential, private 
and intended for only the addressee. 

Should you not be the addressee and receive this e-mail by mistake, kindly 
notify the sender, and delete this e-mail immediately.
Do not disclose or use it in any way. Views and opinions expressed in this 
e-mail are those of the sender unless clearly stated as 
those of Standard Bank Group. 

Standard Bank Group accepts no liability for any loss or damages howsoever 
incurred, or suffered, resulting, or arising, 
from the use of this email or its attachments. 

Standard Bank Group does not warrant the integrity of this e-mail nor that it 
is free of errors, viruses, interception or interference. 

Licensed divisions of the Standard Bank Group are authorised financial services 
providers in terms of the Financial Advisory and 
Intermediary Services Act, No 37 of 2002 (FAIS).

For information about the Standard Bank Group visit our website 
http://www.standardbank.com




  

Re: Using multiple source dirs

2009-05-12 Thread Kamlesh Sangani
multiple source directories configuration does not work with non-maven project. 
see http://jira.codehaus.org/browse/SONAR-623




From: karthikeyan.sivanant...@wipro.com karthikeyan.sivanant...@wipro.com
To: users@maven.apache.org
Sent: Monday, May 11, 2009 11:01:53 PM
Subject: Using multiple source dirs

Hi all,

I'm trying to use sonar light with my non maven project. When I do a mvn
clean install, I get the following error. I've pasted my pom.xml after
the error. I'm using mvn 2.1.0, java 1.5 and sonar 1.7. Any help is
highly appreciated

[INFO]

[INFO] Building OME_SM
[INFO]task-segment: [clean, install]
[INFO]

[INFO] [clean:clean]
[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Error configuring:
org.apache.maven.plugins:maven-resources-plugin. Reas
n: ERROR: Cannot override read-only parameter: resources in goal:
resources:res
urces
[INFO]

[INFO] For more information, run Maven with the -e switch
[INFO]

[INFO] Total time: 2 seconds
[INFO] Finished at: Mon May 11 17:58:31 IST 2009
[INFO] Final Memory: 7M/13M
[INFO]





xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;

xsi:schemaLocation=http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd;

modelVersion4.0.0/modelVersion

groupIdWiproTechnologies/groupId

artifactIdOME_SM/artifactId

nameOME_SM/name

version6.0/version

build

sourceDirectory${basedir}/target/sources/sourceDirectory

plugins

plugin

groupIdorg.apache.maven.plugins/groupId

artifactIdmaven-compiler-plugin/artifactId

configuration

source1.5/source

target1.5/target

excludes

exclude**/*.*/exclude

/excludes

/configuration

/plugin

plugin

groupIdorg.apache.maven.plugins/groupId

artifactIdmaven-resources-plugin/artifactId

version2.3/version

configuration

outputDirectory${basedir}/target/sources/outputDirectory

resources

resource

directory${basedir}/sm_viking/src_release/directory

/resource

!-- resource

directory${basedir}/sm_viking/src_common/directory

/resource --

/resources

/configuration

/plugin

/plugins

/build

properties

sonar.lighttrue/sonar.light

/properties

/project



thanks!


Please do not print this email unless it is absolutely necessary.

The information contained in this electronic message and any attachments to 
this message are intended for the exclusive use of the addressee(s) and may 
contain proprietary, confidential or privileged information. If you are not the 
intended recipient, you should not disseminate, distribute or copy this e-mail. 
Please notify the sender immediately and destroy all copies of this message and 
any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should 
check this email and any attachments for the presence of viruses. The company 
accepts no liability for any damage caused by any virus transmitted by this 
email.

www.wipro.com



  

Re: mvn compile issue

2009-03-09 Thread Kamlesh Sangani
You need to configure maven-compiler-plugin.

put the following in pom.xml

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



From: huser mpinj...@atxg.com
To: users@maven.apache.org
Sent: Monday, March 9, 2009 1:57:53 PM
Subject: mvn compile issue


Hi,

I am new to Maven. I wanted to compile a list of sources using Maven. I get
the following error. The compilation with ANT is fine. What is wrong here ?

C:\workspace\sip\SIPProxy\src\main\java\com\atxg\SIPProxy\SIPProxyMsgHandler\E91
1CallHistory.java:[10,15] generics are not supported in -source 1.3
(use -source 5 or higher to enable generics)
private VectorString sip_message_event;

C:\workspace\sip\SIPProxy\src\main\java\com\atxg\SIPProxy\Manager\SIProxyMsgMana
ger.java:[20,15] generics are not supported in -source 1.3
(use -source 5 or higher to enable generics)
private VectorSIPProxyMsgHandler sessionPool;

http://www.nabble.com/file/p22420560/pom.xml pom.xml mvn --version
Maven version: 2.0.9
Java version: 1.6.0_07
OS name: windows xp version: 5.1 arch: x86 Family: windows

I have attached the POM.xml.

Thanks,

-- 
View this message in context: 
http://www.nabble.com/mvn-compile-issue-tp22420560p22420560.html
Sent from the Maven - Users mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


  

project artifacts returns empty collection

2009-01-17 Thread Kamlesh Sangani
I have a mojo which is bound to generated-sources phase. In the mojo I am 
calling some third party code which expects project's dependecies in the 
classpath. These dependencies are decalred in the project which is calling my 
mojo. So before calling the third party code I need to add these dependecies to 
the classpath. Is there a standard solution to this problem?

I have looked at the mailing list and there are some suggestions of using 
${project.artifacts} to get project dependecies and then change context 
classloader. I tried to decalre the following configuration but artifacts is 
always empty set.

   /**
 * The set of artifact artifacts
 *
 * @parameter expression = ${project.artifacts}
 * @readonly
 * @requiresDependencyResolution runtime
 */
private Collection artifacts;

Do I need to have some other configuration in project/plugin pom to make this 
work? Any help is appreciated.



  

Re: AW: project artifacts returns empty collection

2009-01-17 Thread Kamlesh Sangani
I tried the sample code. But now for the collection injected for the expression 
${project.compileClasspathElements} only has classes folder for the project. It 
does not include any other dependency module jars. Any idea?

Other thing is third party jar that I am calling uses 
getClass().getClassLoader().getResource(). In such case changing thread context 
classloader does not help. Any work around for this use case?





From: Mark Struberg strub...@yahoo.de
To: Maven Users List users@maven.apache.org
Sent: Saturday, January 17, 2009 3:10:38 PM
Subject: AW: project artifacts returns empty collection

you may look at the openjpa-maven-plugin:

https://svn.codehaus.org/mojo/trunk/mojo/openjpa-maven-plugin/

latest version is in my git at http://ns1.backwork.net/git

the interesting code is in
https://svn.codehaus.org/mojo/trunk/mojo/openjpa-maven-plugin/src/main/java/org/codehaus/mojo/openjpa/AbstractOpenJpaMojo.java

protected void extendRealmClasspath()

hth
LieGrue,
strub

--- Kamlesh Sangani xkamle...@yahoo.com schrieb am So, 18.1.2009:

 Von: Kamlesh Sangani xkamle...@yahoo.com
 Betreff: project artifacts returns empty collection
 An: users@maven.apache.org
 Datum: Sonntag, 18. Januar 2009, 0:02
 I have a mojo which is bound to generated-sources phase. In
 the mojo I am calling some third party code which expects
 project's dependecies in the classpath. These
 dependencies are decalred in the project which is calling my
 mojo. So before calling the third party code I need to add
 these dependecies to the classpath. Is there a standard
 solution to this problem?
 
 I have looked at the mailing list and there are some
 suggestions of using ${project.artifacts} to get project
 dependecies and then change context classloader. I tried to
 decalre the following configuration but artifacts is always
 empty set.
 
/**
  * The set of artifact artifacts
  *
  * @parameter expression =
 ${project.artifacts}
  * @readonly
  * @requiresDependencyResolution runtime
  */
 private Collection artifacts;
 
 Do I need to have some other configuration in
 project/plugin pom to make this work? Any help is
 appreciated.




-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


  

Re: AW: project artifacts returns empty collection

2009-01-17 Thread Kamlesh Sangani
Thanks Mark.

1.
The project invoking mojo has a plugin declaration in build tag as follows.

   plugin
groupIdcom.test.maven.plugins/groupId
artifactIdmy-maven-plugin/artifactId
version1.0-SNAPSHOT/version
executions
execution
idrun/id
phasegenerate-sources/phase
goals
goalrun/goal
/goals
/execution
/executions
/plugin

2.
The project also has more dependencies in default scope (compile). I can 
iterate through these dependencies using project.getDependencies() method. But 
${project.compileClasspathElements} only has target/classes folder in it.


3. 
Mojo is executed in the standard lifecycle in generated-sources phase. i do not 
have any custom configuration for lifecycle.





From: Mark Struberg strub...@yahoo.de
To: Maven Users List users@maven.apache.org
Sent: Saturday, January 17, 2009 4:04:23 PM
Subject: Re: AW: project artifacts returns empty collection

What does your pom look like? 
Which scope do the dependencies have?
In which lifecycle is your mojo being executed? standard?

LieGrue,
strub


--- Kamlesh Sangani xkamle...@yahoo.com schrieb am So, 18.1.2009:

 Von: Kamlesh Sangani xkamle...@yahoo.com
 Betreff: Re: AW: project artifacts returns empty collection
 An: Maven Users List users@maven.apache.org
 Datum: Sonntag, 18. Januar 2009, 0:45
 I tried the sample code. But now for the collection injected
 for the expression ${project.compileClasspathElements} only
 has classes folder for the project. It does not include any
 other dependency module jars. Any idea?
 
 Other thing is third party jar that I am calling uses
 getClass().getClassLoader().getResource(). In such case
 changing thread context classloader does not help. Any work
 around for this use case?
 
 
 
 
 
 From: Mark Struberg strub...@yahoo.de
 To: Maven Users List users@maven.apache.org
 Sent: Saturday, January 17, 2009 3:10:38 PM
 Subject: AW: project artifacts returns empty collection
 
 you may look at the openjpa-maven-plugin:
 
 https://svn.codehaus.org/mojo/trunk/mojo/openjpa-maven-plugin/
 
 latest version is in my git at http://ns1.backwork.net/git
 
 the interesting code is in
 https://svn.codehaus.org/mojo/trunk/mojo/openjpa-maven-plugin/src/main/java/org/codehaus/mojo/openjpa/AbstractOpenJpaMojo.java
 
 protected void extendRealmClasspath()
 
 hth
 LieGrue,
 strub
 
 --- Kamlesh Sangani xkamle...@yahoo.com schrieb am
 So, 18.1.2009:
 
  Von: Kamlesh Sangani xkamle...@yahoo.com
  Betreff: project artifacts returns empty collection
  An: users@maven.apache.org
  Datum: Sonntag, 18. Januar 2009, 0:02
  I have a mojo which is bound to generated-sources
 phase. In
  the mojo I am calling some third party code which
 expects
  project's dependecies in the classpath. These
  dependencies are decalred in the project which is
 calling my
  mojo. So before calling the third party code I need to
 add
  these dependecies to the classpath. Is there a
 standard
  solution to this problem?
  
  I have looked at the mailing list and there are some
  suggestions of using ${project.artifacts} to get
 project
  dependecies and then change context classloader. I
 tried to
  decalre the following configuration but artifacts is
 always
  empty set.
  
 /**
   * The set of artifact artifacts
   *
   * @parameter expression =
  ${project.artifacts}
   * @readonly
   * @requiresDependencyResolution runtime
   */
  private Collection artifacts;
  
  Do I need to have some other configuration in
  project/plugin pom to make this work? Any help is
  appreciated.
 
 
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail:
 users-h...@maven.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


  

exclude jars during filtering

2009-01-15 Thread Kamlesh Sangani
I have some jar files under src/test/resources folder. I have enabled
filter for the test resources. Now during filtering jar files get
corrupted. I have tried the following configuration but does not seem
to work.


pluginManagement
plugins
plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-resources-plugin/artifactId
configuration
nonFilteredFileExtensions
nonFilteredFileExtensionjar/nonFilteredFileExtension
/nonFilteredFileExtensions
/configuration
/plugin
/plugins
/pluginManagement

Any help?