RE: help needed with maven antrun plugin

2010-02-05 Thread Haroon Rafique
On Yesterday at 1:26pm, PA=Pankaj Agarwal pankaj_agar...@trimble.com wrote:

PA Here's the exact error.
PA 
PA [INFO] 
PA  
PA [ERROR] BUILD ERROR [INFO] 
PA  
PA [INFO] An Ant BuildException has occured: The following error occurred 
PA while executing this line: build.xml:118: 
PA com.bea.util.jam.internal.javadoc.JavadocClassloadingException: An 
PA error has occurred while invoking javadoc to inspect your source

Here's my experience. I don't remember when I added this, but here is what 
I use as a dependency for the maven-antrun-plugin:

dependency
groupIdsun.jdk/groupId
artifactIdtools/artifactId
version1.6/version
scopesystem/scope
systemPath${java.home}/../lib/tools.jar/systemPath
/dependency

Works for me, YMMV.

Hope that helps.
--
Haroon Rafique
haroon.rafi...@utoronto.ca


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



Re: maven-ant-run plugin 1.3 error java.lang.NoSuchMethodError: org.apache.tools.ant.util.FileUtils.close

2009-11-11 Thread Haroon Rafique

Hi there,

Sorry for breaking the threading in your email reader, but I just found 
the fix for the above subject and alas I don't have the original thread to 
reply to.


In any case, you may look at the thread discussion at nabble:
http://old.nabble.com/maven-ant-run-plugin-1.3-error-java.lang.NoSuchMethodError:-org.apache.tools.ant.util.FileUtils.close-td25806467.html

The root cause is that the OP (Doug Daniels) is using, ant-contrib in 
maven-antrun-plugin. The fix is to add an exclusion for ant:ant in the 
dependency for ant-contrib, as by default it uses ant-1.5. E.g., use:


dependency
groupIdant-contrib/groupId
artifactIdant-contrib/artifactId
version${ant-contrib.ver}/version
exclusions
exclusion
groupIdant/groupId
artifactIdant/artifactId
/exclusion
/exclusions
/dependency

This way, whatever dependency is specified by maven-antrun-plugin will be 
kick in.


Hope it helps someone.

Cheers,
--
Haroon Rafique
haroon.rafi...@utoronto.ca


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



scpexe verbose output (how to suppress)

2009-05-15 Thread Haroon Rafique

Hi,

I'm using maven 2.0.9 on sun jdk 1.6.0_11 on a linux machine. I'm also 
using the maven-upload-plugin (1.1) to copy an .ear file to an external 
machine using the upload goal. The configuration section of that plugin 
has a urlscpexe://server.ip/directory/path/url. I also have 
password-less ssh key-based login working for that user (no problems 
there).


All in all, everything works fine.

Except for one minor detail.

The verbose output produced (by scpexe?? or maven??) during the file 
upload (consisting of a single line with bunch of ) is a little 
annoying. We are using continuous integration and to look at 6,829 # marks 
all on one line causes fair bit of horizontal scrolling (the .ear in 
question is to the tune of 27MB).


1) Is this the right place to look for answers?
2) If yes, does anyone know what's responsible for printing those # marks 
and how to suppress them?


Thanks,
--
Haroon Rafique
haroon.rafi...@utoronto.ca


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



Re: [SURVEY] How does your team retrieve artifacts?

2008-05-21 Thread Haroon Rafique
[X] Our team uses HTTP to retrieve our artifacts

--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: [2.0.9 RC7] Release Candidate testing

2008-04-03 Thread Haroon Rafique
On Yesterday at 5:52pm, BEF=Brian E. Fox [EMAIL PROTECTED] wrote:

BEF Thank you everyone for the testing and confirmatory responses so far. 
BEF It helps to gauge the progress. There was one regression identified 
BEF in 2.0.9 RC6: (MNG-3495: NPE at 
BEF org.apache.maven.wagon.repository.Repository.hashCode). This has been 
BEF fixed and RC7 posted.
BEF 
BEF [..snip..]

+1
No problems with my projects

Thanks,
--
Haroon Rafique
[EMAIL PROTECTED]


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



surefire 2.4.2 fixes manifest issue (was Re: [ANN] Maven Surefire Plugin 2.4.1 for Maven 2 Released)

2008-02-21 Thread Haroon Rafique
On Feb 7 at 6:01pm, DF=Dan Fabulich [EMAIL PROTECTED] wrote:

DF [..snip..]
DF 
DF Ah, hearing that makes me strongly suspect that this is SUREFIRE-445 and
DF SUREFIRE-451.
DF 
DF http://jira.codehaus.org/browse/SUREFIRE-445
DF http://jira.codehaus.org/browse/SUREFIRE-451
DF 
DF Thanks for doing this research; I've moved these bugs into the upcoming
DF 2.4.2 release.
DF 
DF -Dan
DF 

Hi Dan,

I can report that my earlier reported problems with jdk 1.6 and surefire 
2.4.1 and errors with the manifest have now been fixed with surefire 
2.4.2. Running under cruisecontrol with surefire 2.4.2 and the jdk 1.6, I 
no longer get the manifest related errors.

Regards,
--
Haroon Rafique
[EMAIL PROTECTED]


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



surefire-booter manifest issue (was Re: Surefire 2.4.1 classpath order)

2008-02-15 Thread Haroon Rafique
On Today at 4:50pm, ak=amit kumar [EMAIL PROTECTED] wrote:

ak Hi,
ak I have another related query regarding surefire, all of a sudden from 
ak today we started getting this error while executing JUnit tasks, the 
ak compilation of source file happens fine and the when compiling the 
ak test source files, the maven gives build failure telling that it was 
ak not able
ak 

Its not exactly related but you might be running into:
http://jira.codehaus.org/browse/SUREFIRE-451

Its been fixed and should be in 2.4.2 (I have no idea when it will be 
released. I am not a committer).

You can read the last comment on the jira which points you to a previous 
thread on the mailing list:
http://jira.codehaus.org/browse/SUREFIRE-451#action_122858

ak 
ak to load main class from
ak C:\WINDOWS\TEMP\surefirebooter59557.jar
ak 
ak What is going wrong here?
ak Could someone please help on this?
ak 
ak Regards,
ak Amit
ak 

Cheers,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: [ANN] Maven Surefire Plugin 2.4.1 for Maven 2 Released

2008-02-07 Thread Haroon Rafique
On Today at 3:30pm, DD=Donnchadh Ó Donnabháin [EMAIL PROTECTED] wrote:

DD   Hi Dan,
DD 
DD When I switch from surefire 2.4 to 2.4.1 I get the error below.
DD /tmp/surefirebooter22682.jar doesn't seem to even exist. Any idea what
DD might be causing this?
DD 
DD   Thanks
DD 
DD Donnchadh
DD 

Funny that you mention that. It happens for me too on jdk 1.6.0_04 but 
only when running under cruisecontrol. I'm on maven 2.0.8, surefire 2.4.

Later,
--
Haroon Rafique
[EMAIL PROTECTED]

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

Re: [ANN] Maven Surefire Plugin 2.4.1 for Maven 2 Released

2008-02-07 Thread Haroon Rafique
On Today at 3:30pm, DD=Donnchadh Ó Donnabháin [EMAIL PROTECTED] wrote:

DD   Hi Dan,
DD 
DD When I switch from surefire 2.4 to 2.4.1 I get the error below. 
DD /tmp/surefirebooter22682.jar doesn't seem to even exist. Any idea what 
DD might be causing this?
DD 

Not knowing much about surefirebooter, I can at least tell you 
(paraphrasing here) that the /tmp/surefirebooter*.jar files are created at 
runtime and then deleted when the test is over. If you run with mvn -X, 
the /tmp/surefirebooter*.jar will be left in tact to aid in the debugging 
process.

For me when the error about Failed to load Main-Class manifest attribute 
from /tmp/surefirebooter???.jar appeared, I re-ran the tests with mvn -X 
and then opened up the /tmp/surefirebooter???.jar file. It is a .jar file 
with only one entry META-INF/MANIFEST.MF. Inside the MANIFEST.MF there are 
2 entries. Class-Path and Main-Class. Sure enough, the file was in tact, 
yet surefirebooter would say it can't find the Main-Class. You can even 
try the actual java -jar /tmp/surebooter???.jar . command and it 
still failed.

Looking a little bit more, I was able to extract the MANIFEST.MF file and 
change its format from dos to unix in vim and repackaged it back into 
a jar and sure enough the java -jar /tmp/surefirebooter???.jar . 
command was able to run.

This is as far as I've gotten so far.

Two other data points:

1) Problems are fixed when dropping jdk to 1.5.0_14
2) Problem only appears running inside cruisecontrol (not on the command 
   line)

I would be tempted to file a jira but my project is pretty big and I'm 
finding it absolutely difficult to localize the issue so that I can 
present a minimal test case.

So, with the information that I have provided to you so far, hopefully you 
can provide a minimal test case :-) (or at least, I can wish).

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

Re: Using maven for JavaScript projects

2007-10-01 Thread Haroon Rafique
On Today at 7:09am, ndl=nicolas de loof [EMAIL PROTECTED] wrote:

ndl I've created a wiki entry
ndl (http://hammerfest.wiki.sourceforge.net/mavan-javascript-tools)
ndl to resume the ideas exposed in this thread.
ndl 
ndl please be nice and don't blame me for my ugly english ;-)
ndl (any native english reader is welcome to fix my linguistics errors)
ndl 

Hi Nico,

Could you add another js tool to the list? I haven't started using it, but 
it also looks promising in the link/compress category.

Its the yuicompressor-maven-plugin
http://alchim.sourceforge.net/yuicompressor-maven-plugin/overview.html
based on YUICompressor:
http://www.julienlecomte.net/blog/2007/09/28/yui-compressor-version-221-now-available/
http://www.julienlecomte.net/yuicompressor/


ndl Nico
ndl 

Later,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: Using maven for JavaScript projects

2007-10-01 Thread Haroon Rafique
On Today at 9:56am, HR=Haroon Rafique [EMAIL PROTECTED] wrote:

HR 
HR Hi Nico,
HR 
HR Could you add another js tool to the list? I haven't started using it, but 
HR it also looks promising in the link/compress category.
HR 
HR Its the yuicompressor-maven-plugin
HR http://alchim.sourceforge.net/yuicompressor-maven-plugin/overview.html
HR based on YUICompressor:
HR 
http://www.julienlecomte.net/blog/2007/09/28/yui-compressor-version-221-now-available/
HR http://www.julienlecomte.net/yuicompressor/
HR 

Sorry for the noise. I looked up my sourceforge ID and reset the password 
and updated the wiki with an entry for YUI Compressor Maven Plugin.

Cheers,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: TestCase and resources in src/main/webapp

2007-08-13 Thread Haroon Rafique

On Yesterday at 9:05pm, =[EMAIL PROTECTED] [EMAIL PROTECTED] wrote:


  [..snip..]

this doesn't work as src/main/webapp/ is not on the classpath. Is 
there a way to tell maven to have src/main/webapp on its classpath? Or 
what else is best practice to test resources in src/main/webapp?


kind regards,
janning



Hi Janning,

You cannot achieve this with the current surefire.

We do it by patching surefire. Essentially, by using the patch:
http://jira.codehaus.org/secure/attachment/23139/additionalClasspaths.patch
from this JIRA item:
http://jira.codehaus.org/browse/SUREFIRE-118
surefire now has the capability to add additional classpath elements. If 
you like this feature, vote for this jira item. I have been using this 
patch for about almost a year now.


In our case our plugin config looks something like:

plugin
artifactIdmaven-surefire-plugin/artifactId
version${surefire.ver}/version
configuration
additionalClasspathElements
additionalClasspathElement
src/main/webapp
/additionalClasspathElement
/additionalClasspathElements
/configuration
/plugin

You can add more additionalClasspathElement nodes based upon your needs.

Hope that helps.

Cheers,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: [m2] add resources to surefire execution

2007-02-26 Thread Haroon Rafique
On Friday at 8:03am, DT=Dan Tran [EMAIL PROTECTED] wrote:

DT perhaps make a request to to surefire plugin to allow addition of classpath
DT 
DT -D
DT 

Bug report exists already:

http://jira.codehaus.org/browse/SUREFIRE-118

Please vote for it.
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: Ant-Contrib foreach in Maven 2

2006-12-05 Thread Haroon Rafique
On Today at 11:30am, MAUGM=Morgovsky, Alexander (US - Glen Mills)...:

AM I am trying to create an Ant task using the maven-antrun-plugin in 
AM Maven 2.  I would like to use the optional task foreach.  In Ant, I 
AM did this by declaring the Ant-Contrib jar in a taskdef object in the 
AM build.xml. How may I do this in Maven 2?  Thanks.
AM 
AM 

I have the following in the dependencies section of my pom

dependency
groupIdant-contrib/groupId
artifactIdant-contrib/artifactId
version0.6/version
scopeprovided/scope
/dependency

then in my maven-antrun-plugin tasks section, I have the following:

   configuration
   tasks
   taskdef resource=net/sf/antcontrib/antcontrib.properties  
 
classpathref=maven.compile.classpath/
   ..
   /tasks
   /configuration

Hope this helps.
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: Ant-Contrib foreach in Maven 2

2006-12-05 Thread Haroon Rafique
On Today at 5:05pm, HR=Haroon Rafique [EMAIL PROTECTED] wrote:

HR I have the following in the dependencies section of my pom
HR 
HR dependency
HR groupIdant-contrib/groupId
HR artifactIdant-contrib/artifactId
HR version0.6/version
HR scopeprovided/scope
HR /dependency
HR 

The maven2 official repos have the following versions:
1.0b2
20020829
I decided to put 0.6 in my internal repo (which is how maven finds it now 
in my project).

HR 
HR [..snip..]
HR 

--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: Resource filtering using environment variables

2006-11-09 Thread Haroon Rafique
On Today at 2:08am, GT=Gareth Tilley [EMAIL PROTECTED] wrote:

GT 
GT Hi All,
GT 
GT Gunther Popp-2 wrote:
GT - All (platform-specific) Environment variables (Just add the prefix
GT env. For example ${env.M2_HOME} returns the Maven2 installation path).
GT 
GT Has anyone actually been able to get this working? All of the filtering
GT works fine for me, but the environment variable stuff does not.  As a test I
GT have a properties file that contains:
GT ${env.JAVA_HOME}
GT ${user.home}
GT ${pom.version}
GT 
GT After the process-resources phase (with filtering turn on in the pom), the
GT file looks like this:
GT ${env.JAVA_HOME}
GT /home/build
GT 1.2-SNAPSHOT
GT 
GT JAVA_HOME is definitely set, is there something I am doing wrong, or does
GT this just not work?
GT 
GT Regards
GT Gareth 
GT 

Hi Gareth,

Environment variables tend to be second-class citizens in my experience. 
See my earlier post about profile activation based on environment 
variables:

http://www.nabble.com/profile-activation-based-on-environment-variables-t2585492s177.html

In addition, looking at the source for ResourcesMojo.java
http://svn.apache.org/viewvc/maven/plugins/trunk/maven-resources-plugin/src/main/java/org/apache/maven/plugin/resources/ResourcesMojo.java?revision=422969view=markup
we see that there is no mention of environment variables during filtering 
(just system properties and project properties):

filterProperties = new Properties();

// System properties
filterProperties.putAll( System.getProperties() );

// Project properties
filterProperties.putAll( project.getProperties() );

I am not familiar with the maven codebase at all, but I might try my luck 
with figuring this out (when I get some spare time).

Later,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: Resource filtering using environment variables

2006-11-09 Thread Haroon Rafique
On Today at 11:20am, HR=Haroon Rafique [EMAIL PROTECTED] wrote:

HR [..snip..]
HR 

Something like the following should work (not tested):

import org.codehaus.plexus.util.cli.CommandLineUtils;


HR filterProperties = new Properties();
HR 
HR // System properties
HR filterProperties.putAll( System.getProperties() );
HR 
HR // Project properties
HR filterProperties.putAll( project.getProperties() );
HR 

follow the above two calls with:

// Environment variables
filterProperties.putAll( CommandLineUtils.getSystemEnvVars() );

Anyone willing to give it a try?

Later,
--
Haroon Rafique
[EMAIL PROTECTED]


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



Re: profile activation based on environment variables

2006-11-07 Thread Haroon Rafique
On Today at 11:07am, AB=Arnaud Bailly [EMAIL PROTECTED] wrote:

AB [..snip..]
AB 
AB Not sure but I think that what you call environment variables are
AB actually system properties set on maven's cli: Try
AB 
AB activation
AB property
AB nameBLAH/name
AB valueblah/value
AB /property
AB /activation
AB 
AB mvn -DBLAH=blah help:active-profile
AB 
AB 
AB HTH

Hi Arnaud,

Thanks for the reply, but I'm positive I want environment variables and 
not system properties. From http://maven.apache.org/settings.html

env.X: Prefixing a variable with env. will return the shell's
environment variable. For example, ${env.PATH} contains the $path
environment variable (%PATH% in Windows).

I believe this has been in maven since 2.0.1+ (was implemented via MNG-1525).
http://jira.codehaus.org/browse/MNG-1525

Any more insight would be helpful.

Regards,
--
Haroon Rafique
[EMAIL PROTECTED]


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



profile activation based on environment variables

2006-11-06 Thread Haroon Rafique

Hi,

I'm using maven 2.0.4 on a Gentoo Linux machine. Does anyone have 
experience in activating profiles based on environment variables? I figure 
using the env prefix would do the trick. So, far I have tried:


profile
idharoon-workstation/id
activation
property
nameenv.BLAH/name
valueblah/value
/property
/activation
properties
user.install.root/www/tomcat/user.install.root
/properties
/profile

After setting:
export BLAH=blah
and execuging:
mvn help:active-profile
I still get:

[INFO] [help:active-profiles]
[INFO]
Active Profiles for Project 'ca.utoronto.sis:sws:war:1.0':

There are no active profiles.

On an aside, the only way I can activate that profile is to use !env.BLAH:

profile
idharoon-workstation/id
activation
property
name!env.BLAH/name
/property
/activation
properties
user.install.root/www/tomcat/user.install.root
/properties
/profile

Is this a bug? Should I raise a jira issue?

What I'm eventually trying to do is to do some per host profile 
activation, so I was thinking of using env.HOSTNAME as the activation. Any 
ideas to do something similar?


Thanks,
--
Haroon Rafique
[EMAIL PROTECTED]


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