You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Jan T. Kim" <j....@uea.ac.uk> on 2010/07/14 03:37:38 UTC

Can the javac message format be changed?

Dear All,

is it possiible to change the format of error messages to that which the
standalone javac compiler produces? I haven't found anything on that in
the compiler:compile at maven.apache.org.

Sorry if this is a silly question, I'd verny much value pointers to the
relevant documentation.

Best regards, Jan
-- 
 +- Jan T. Kim -------------------------------------------------------+
 |             email: j.kim@uea.ac.uk                                 |
 |             WWW:   http://www.cmp.uea.ac.uk/people/jtk             |
 *-----=<  hierarchical systems are for files, not for humans  >=-----*

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


Re: Can the javac message format be changed?

Posted by Baptiste MATHUS <ml...@batmat.net>.
I don't think it's possible since maven just relies on the current JDK being
used, and so the output is just the one issued by that JDK. I guess it could
try and parse the output, but I'm not sure this would be a good idea.

Maybe you could try and explain a bit more why you want to do. This way, you
might be adviced on filing something in the tracker or not.

Cheers.
PS : posting offline. So this answer might be irrelevant when it'll arrive.
If so, please excuse me.

Le 14 juillet 2010 03:37:38 UTC+2, Jan T. Kim <j....@uea.ac.uk> a écrit :

> Dear All,
>
> is it possiible to change the format of error messages to that which the
> standalone javac compiler produces? I haven't found anything on that in
> the compiler:compile at maven.apache.org.
>
> Sorry if this is a silly question, I'd verny much value pointers to the
> relevant documentation.
>
> Best regards, Jan
> --
>  +- Jan T. Kim -------------------------------------------------------+
>  |             email: j.kim@uea.ac.uk                                 |
>  |             WWW:   http://www.cmp.uea.ac.uk/people/jtk             |
>  *-----=<  hierarchical systems are for files, not for humans  >=-----*
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

Re: Problem with uniqueVersion=false in 3.0 beta1

Posted by Brian Fox <br...@infinity.nu>.
Because the code to support that was a giant rats nest, and everything
was re-written. It's mostly an anti-pattern to use so the developers
rewriting that code didn't re-implement it. So far no one has stepped
up to provide a patch to put it back in. That's essentially it in a
nutshell.

On Fri, Aug 6, 2010 at 12:15 PM, Adam Krieg <ak...@pragmatrading.com> wrote:
> We have a local repo manager and it still takes a fixed amount of time per artifact.  It would take a few minutes to totally rebuild a local repo as we have a fair number (hundreds) of artifacts, and Maven itself requires a bunch of plugins just to get started.  Granted I could just delete my group from the local repo tree to speed things up, but I don't understand why we need to do this when the SNAPSHOT notion seemed to work just fine for us.  The SNAPSHOT version was useful and I'm not sure why it was taken out in M3.
>
> -----Original Message-----
> From: Brian Fox [mailto:brianf@infinity.nu]
> Sent: Friday, August 06, 2010 11:42 AM
> To: Maven Users List
> Subject: Re: Problem with uniqueVersion=false in 3.0 beta1
>
> No, but with a repo manager, it's pretty quick to wipe the local and
> refetch everything cleanly from the local network.
>
> On Fri, Aug 6, 2010 at 10:31 AM, Adam Krieg <ak...@pragmatrading.com> wrote:
>> Is the local repository smart enough to clear out the old snapshots?  I'm worried about tons of irrelevant artifacts.
>>
>> -----Original Message-----
>> From: Stephen Connolly [mailto:stephen.alan.connolly@gmail.com]
>> Sent: Thursday, July 15, 2010 4:00 PM
>> To: Maven Users List
>> Subject: Re: Problem with uniqueVersion=false in 3.0 beta1
>>
>> You recall correctly, uniqueSnapshots will always be true for M3
>> irrespective of what you try to set it to
>>
>> -Stephen
>>
>> P.S. I don't understand exactly why... I think it has something to do with
>> Repository managers being sufficiently good that they can reclaim the disk
>> space for you so the non-unique is no longer required.
>>
>> On 15 July 2010 20:28, Anders Hammar <an...@hammar.net> wrote:
>>
>>> IIRC Maven 3 only supports unique versioned snapshots (currently). There
>>> was
>>> some discussion easlier here on the mailing list regarding that. Search
>>> some
>>> archive for more info.
>>>
>>> /Anders
>>>
>>> On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com>
>>> wrote:
>>>
>>> > I'm trying to configure Maven to not create unique snapshots.
>>> >
>>> > When using the following settings in Maven 2.2.1, this works:
>>> >
>>> >        <snapshotRepository>
>>> >            <uniqueVersion>false</uniqueVersion>
>>> > ....
>>> >
>>> >
>>> > However when I run with Maven 3.0 beta 1, I get autogenerated numbers
>>> > appended, as if uniqueVersion was true.
>>> >
>>> >
>>> > Is anyone else seeing this behavior?
>>> >
>>> > Disclaimer: http://pragmatrading.com/disclaimer.html
>>> >
>>>
>>
>> Disclaimer: http://pragmatrading.com/disclaimer.html
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
> Disclaimer: http://pragmatrading.com/disclaimer.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

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


RE: Problem with uniqueVersion=false in 3.0 beta1

Posted by Adam Krieg <ak...@pragmatrading.com>.
We have a local repo manager and it still takes a fixed amount of time per artifact.  It would take a few minutes to totally rebuild a local repo as we have a fair number (hundreds) of artifacts, and Maven itself requires a bunch of plugins just to get started.  Granted I could just delete my group from the local repo tree to speed things up, but I don't understand why we need to do this when the SNAPSHOT notion seemed to work just fine for us.  The SNAPSHOT version was useful and I'm not sure why it was taken out in M3.

-----Original Message-----
From: Brian Fox [mailto:brianf@infinity.nu]
Sent: Friday, August 06, 2010 11:42 AM
To: Maven Users List
Subject: Re: Problem with uniqueVersion=false in 3.0 beta1

No, but with a repo manager, it's pretty quick to wipe the local and
refetch everything cleanly from the local network.

On Fri, Aug 6, 2010 at 10:31 AM, Adam Krieg <ak...@pragmatrading.com> wrote:
> Is the local repository smart enough to clear out the old snapshots?  I'm worried about tons of irrelevant artifacts.
>
> -----Original Message-----
> From: Stephen Connolly [mailto:stephen.alan.connolly@gmail.com]
> Sent: Thursday, July 15, 2010 4:00 PM
> To: Maven Users List
> Subject: Re: Problem with uniqueVersion=false in 3.0 beta1
>
> You recall correctly, uniqueSnapshots will always be true for M3
> irrespective of what you try to set it to
>
> -Stephen
>
> P.S. I don't understand exactly why... I think it has something to do with
> Repository managers being sufficiently good that they can reclaim the disk
> space for you so the non-unique is no longer required.
>
> On 15 July 2010 20:28, Anders Hammar <an...@hammar.net> wrote:
>
>> IIRC Maven 3 only supports unique versioned snapshots (currently). There
>> was
>> some discussion easlier here on the mailing list regarding that. Search
>> some
>> archive for more info.
>>
>> /Anders
>>
>> On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com>
>> wrote:
>>
>> > I'm trying to configure Maven to not create unique snapshots.
>> >
>> > When using the following settings in Maven 2.2.1, this works:
>> >
>> >        <snapshotRepository>
>> >            <uniqueVersion>false</uniqueVersion>
>> > ....
>> >
>> >
>> > However when I run with Maven 3.0 beta 1, I get autogenerated numbers
>> > appended, as if uniqueVersion was true.
>> >
>> >
>> > Is anyone else seeing this behavior?
>> >
>> > Disclaimer: http://pragmatrading.com/disclaimer.html
>> >
>>
>
> Disclaimer: http://pragmatrading.com/disclaimer.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

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


Disclaimer: http://pragmatrading.com/disclaimer.html

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


Re: Problem with uniqueVersion=false in 3.0 beta1

Posted by Brian Fox <br...@infinity.nu>.
No, but with a repo manager, it's pretty quick to wipe the local and
refetch everything cleanly from the local network.

On Fri, Aug 6, 2010 at 10:31 AM, Adam Krieg <ak...@pragmatrading.com> wrote:
> Is the local repository smart enough to clear out the old snapshots?  I'm worried about tons of irrelevant artifacts.
>
> -----Original Message-----
> From: Stephen Connolly [mailto:stephen.alan.connolly@gmail.com]
> Sent: Thursday, July 15, 2010 4:00 PM
> To: Maven Users List
> Subject: Re: Problem with uniqueVersion=false in 3.0 beta1
>
> You recall correctly, uniqueSnapshots will always be true for M3
> irrespective of what you try to set it to
>
> -Stephen
>
> P.S. I don't understand exactly why... I think it has something to do with
> Repository managers being sufficiently good that they can reclaim the disk
> space for you so the non-unique is no longer required.
>
> On 15 July 2010 20:28, Anders Hammar <an...@hammar.net> wrote:
>
>> IIRC Maven 3 only supports unique versioned snapshots (currently). There
>> was
>> some discussion easlier here on the mailing list regarding that. Search
>> some
>> archive for more info.
>>
>> /Anders
>>
>> On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com>
>> wrote:
>>
>> > I'm trying to configure Maven to not create unique snapshots.
>> >
>> > When using the following settings in Maven 2.2.1, this works:
>> >
>> >        <snapshotRepository>
>> >            <uniqueVersion>false</uniqueVersion>
>> > ....
>> >
>> >
>> > However when I run with Maven 3.0 beta 1, I get autogenerated numbers
>> > appended, as if uniqueVersion was true.
>> >
>> >
>> > Is anyone else seeing this behavior?
>> >
>> > Disclaimer: http://pragmatrading.com/disclaimer.html
>> >
>>
>
> Disclaimer: http://pragmatrading.com/disclaimer.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

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


RE: Problem with uniqueVersion=false in 3.0 beta1

Posted by Adam Krieg <ak...@pragmatrading.com>.
Is the local repository smart enough to clear out the old snapshots?  I'm worried about tons of irrelevant artifacts.

-----Original Message-----
From: Stephen Connolly [mailto:stephen.alan.connolly@gmail.com]
Sent: Thursday, July 15, 2010 4:00 PM
To: Maven Users List
Subject: Re: Problem with uniqueVersion=false in 3.0 beta1

You recall correctly, uniqueSnapshots will always be true for M3
irrespective of what you try to set it to

-Stephen

P.S. I don't understand exactly why... I think it has something to do with
Repository managers being sufficiently good that they can reclaim the disk
space for you so the non-unique is no longer required.

On 15 July 2010 20:28, Anders Hammar <an...@hammar.net> wrote:

> IIRC Maven 3 only supports unique versioned snapshots (currently). There
> was
> some discussion easlier here on the mailing list regarding that. Search
> some
> archive for more info.
>
> /Anders
>
> On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com>
> wrote:
>
> > I'm trying to configure Maven to not create unique snapshots.
> >
> > When using the following settings in Maven 2.2.1, this works:
> >
> >        <snapshotRepository>
> >            <uniqueVersion>false</uniqueVersion>
> > ....
> >
> >
> > However when I run with Maven 3.0 beta 1, I get autogenerated numbers
> > appended, as if uniqueVersion was true.
> >
> >
> > Is anyone else seeing this behavior?
> >
> > Disclaimer: http://pragmatrading.com/disclaimer.html
> >
>

Disclaimer: http://pragmatrading.com/disclaimer.html

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


Re: Problem with uniqueVersion=false in 3.0 beta1

Posted by Stephen Connolly <st...@gmail.com>.
You recall correctly, uniqueSnapshots will always be true for M3
irrespective of what you try to set it to

-Stephen

P.S. I don't understand exactly why... I think it has something to do with
Repository managers being sufficiently good that they can reclaim the disk
space for you so the non-unique is no longer required.

On 15 July 2010 20:28, Anders Hammar <an...@hammar.net> wrote:

> IIRC Maven 3 only supports unique versioned snapshots (currently). There
> was
> some discussion easlier here on the mailing list regarding that. Search
> some
> archive for more info.
>
> /Anders
>
> On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com>
> wrote:
>
> > I'm trying to configure Maven to not create unique snapshots.
> >
> > When using the following settings in Maven 2.2.1, this works:
> >
> >        <snapshotRepository>
> >            <uniqueVersion>false</uniqueVersion>
> > ....
> >
> >
> > However when I run with Maven 3.0 beta 1, I get autogenerated numbers
> > appended, as if uniqueVersion was true.
> >
> >
> > Is anyone else seeing this behavior?
> >
> > Disclaimer: http://pragmatrading.com/disclaimer.html
> >
>

Re: Problem with uniqueVersion=false in 3.0 beta1

Posted by Anders Hammar <an...@hammar.net>.
IIRC Maven 3 only supports unique versioned snapshots (currently). There was
some discussion easlier here on the mailing list regarding that. Search some
archive for more info.

/Anders

On Thu, Jul 15, 2010 at 21:24, Adam Krieg <ak...@pragmatrading.com> wrote:

> I'm trying to configure Maven to not create unique snapshots.
>
> When using the following settings in Maven 2.2.1, this works:
>
>        <snapshotRepository>
>            <uniqueVersion>false</uniqueVersion>
> ....
>
>
> However when I run with Maven 3.0 beta 1, I get autogenerated numbers
> appended, as if uniqueVersion was true.
>
>
> Is anyone else seeing this behavior?
>
> Disclaimer: http://pragmatrading.com/disclaimer.html
>

Problem with uniqueVersion=false in 3.0 beta1

Posted by Adam Krieg <ak...@pragmatrading.com>.
I'm trying to configure Maven to not create unique snapshots.

When using the following settings in Maven 2.2.1, this works:

        <snapshotRepository>
            <uniqueVersion>false</uniqueVersion>
....


However when I run with Maven 3.0 beta 1, I get autogenerated numbers appended, as if uniqueVersion was true.


Is anyone else seeing this behavior?

Disclaimer: http://pragmatrading.com/disclaimer.html

Re: Can the javac message format be changed?

Posted by Wayne Fay <wa...@gmail.com>.
> separated from the file name by ":[". So as a thought, perhaps a future
> version of maven could change the format to contain a fixed, regexp-friendly
> string -- or perhaps error message formats could become configurable via

To increase the possibility this might actually happen some day:
1. File a bug report in JIRA against MNG project
2. Attach a patch that provides the suggested functionality
3. Attach a test (or more than 1) that demonstrates the functionality

Simply talking about this on the Maven Users list is not going to get
anything done in this regard.

Wayne

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


Re: Can the javac message format be changed?

Posted by "Jan T. Kim" <j....@uea.ac.uk>.
On Wed, Jul 14, 2010 at 02:56:33PM +0100, Wayne Fay wrote:
> > is it possiible to change the format of error messages to that which the
> > standalone javac compiler produces? I haven't found anything on that in
> > the compiler:compile at maven.apache.org.
> 
> If you can find a way to do this with plain old Javac from the command
> line, then you can probably make it work in Maven.
> 
> What is the command line equivalent "javac .... blah.java" that you
> want to utilize?

the background of my question is that I'd like emacs to be able of jumping
to the source that caused the error. That has stopped working for me since
switching to Maven.

However, I've now managed to restorE that to a reasonable extent (I hope)
by adding an additional regular expression to the list that emacs uses
for parsing compilation errors by adding

    (setq compilation-error-regexp-alist (cons '("^\\(\\[WARNING\\] \\)?\\(/[^:]+\\):\\[\\([0-9]+\\),\\([0-9]+\\)\\]" 2 3 4) compilation-error-regexp-alist))

to my ~/.emacs startup file.

The maven compilation error messages don't contain any constant text that
one could easily use for matching with a regular expression, my regexp
above just relies on error messages starting with a forward slash (as part
of the absolute path to the source file) and that the line number is
separated from the file name by ":[". So as a thought, perhaps a future
version of maven could change the format to contain a fixed, regexp-friendly
string -- or perhaps error message formats could become configurable via
pom settings.

Best regards, Jan
-- 
 +- Jan T. Kim -------------------------------------------------------+
 |             email: j.kim@uea.ac.uk                                 |
 |             WWW:   http://www.cmp.uea.ac.uk/people/jtk             |
 *-----=<  hierarchical systems are for files, not for humans  >=-----*

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


Re: Can the javac message format be changed?

Posted by Wayne Fay <wa...@gmail.com>.
> is it possiible to change the format of error messages to that which the
> standalone javac compiler produces? I haven't found anything on that in
> the compiler:compile at maven.apache.org.

If you can find a way to do this with plain old Javac from the command
line, then you can probably make it work in Maven.

What is the command line equivalent "javac .... blah.java" that you
want to utilize?

Wayne

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