Re: [maven-source-plugin] 3.3.0 incompatible with 3.2.1

2023-08-15 Thread Gary Gregory
On Tue, Aug 15, 2023 at 2:17 PM Konrad Windszus  wrote:
>
> Hi,
> The error message is introduced with 
> https://issues.apache.org/jira/browse/MSOURCES-121 in 3.3.0:
> If you have two goals both attaching an artifact with the same classifier and 
> extension to the current project they will overwrite each other.
> Please check which classifiers are used for both goals:
> By default they should differ: 
> https://maven.apache.org/plugins/maven-source-plugin/test-jar-no-fork-mojo.html#classifier
>  and 
> https://maven.apache.org/plugins/maven-source-plugin/jar-no-fork-mojo.html#classifier
>
> If it can be reproduced without the same classifier parameter, please raise a 
> JIRA issue.

Hi,

We don't specify classifiers and we need to create two jars: the
source jar and the test source jar. I created
https://issues.apache.org/jira/browse/MSOURCES-143

TY!
Gary

>
> Thanks,
> Konrad
>
>
>
>
> > On 15. Aug 2023, at 19:48, Gary Gregory  wrote:
> >
> > On Tue, Aug 15, 2023 at 12:42 PM Michael Osipov  > > wrote:
> >>
> >> Am 2023-08-15 um 14:57 schrieb Gary Gregory:
> >>> Hi All,
> >>>
> >>> In Commons Parent [1], we want to configure child POMs to build both
> >>> source and test sources, so we say (among other things):
> >>>
> >>>   
> >>> maven-source-plugin
> >>> 
> >>>   
> >>> create-source-jar
> >>> 
> >>>   jar-no-fork
> >>>   test-jar-no-fork
> >>> 
> >>>   
> >>> 
> >>>   
> >>>
> >>> Which appears to no longer work in 3.3.0:
> >>>
> >>> [ERROR] Failed to execute goal
> >>> org.apache.maven.plugins:maven-source-plugin:3.3.0:jar-no-fork
> >>> (create-source-jar) on project commons-cli: Presumably you have
> >>> configured maven-source-plugn to execute twice times in your build.
> >>> You have to configure a classifier for at least on of them. -> [Help
> >>> 1]
> >>>
> >>> Am I missing something?
> >>
> >> Do you invoke two overlapping phases? E.g., package and install?
> >
> > I get the error with 'mvn clean package'
> >
> > Gary
> > PS: There is also a typo in the error message: maven-source-plugn ->
> > maven-source-plugin
> >
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org 
> >> 
> >> For additional commands, e-mail: dev-h...@maven.apache.org 
> >> 
> >>
> >
> > -
> > To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org 
> > 
> > For additional commands, e-mail: dev-h...@maven.apache.org 
> > 

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



Re: [maven-source-plugin] 3.3.0 incompatible with 3.2.1

2023-08-15 Thread Konrad Windszus

> PS: There is also a typo in the error message: maven-source-plugn ->
> maven-source-plugin
> 
Reported and fixed already in master: 
https://github.com/apache/maven-source-plugin/commit/1edeea47f80bc5c5903e88c1adbff56501248a8b



Re: [maven-source-plugin] 3.3.0 incompatible with 3.2.1

2023-08-15 Thread Konrad Windszus
Hi,
The error message is introduced with 
https://issues.apache.org/jira/browse/MSOURCES-121 in 3.3.0:
If you have two goals both attaching an artifact with the same classifier and 
extension to the current project they will overwrite each other.
Please check which classifiers are used for both goals:
By default they should differ: 
https://maven.apache.org/plugins/maven-source-plugin/test-jar-no-fork-mojo.html#classifier
 and 
https://maven.apache.org/plugins/maven-source-plugin/jar-no-fork-mojo.html#classifier

If it can be reproduced without the same classifier parameter, please raise a 
JIRA issue.

Thanks,
Konrad




> On 15. Aug 2023, at 19:48, Gary Gregory  wrote:
> 
> On Tue, Aug 15, 2023 at 12:42 PM Michael Osipov  > wrote:
>> 
>> Am 2023-08-15 um 14:57 schrieb Gary Gregory:
>>> Hi All,
>>> 
>>> In Commons Parent [1], we want to configure child POMs to build both
>>> source and test sources, so we say (among other things):
>>> 
>>>   
>>> maven-source-plugin
>>> 
>>>   
>>> create-source-jar
>>> 
>>>   jar-no-fork
>>>   test-jar-no-fork
>>> 
>>>   
>>> 
>>>   
>>> 
>>> Which appears to no longer work in 3.3.0:
>>> 
>>> [ERROR] Failed to execute goal
>>> org.apache.maven.plugins:maven-source-plugin:3.3.0:jar-no-fork
>>> (create-source-jar) on project commons-cli: Presumably you have
>>> configured maven-source-plugn to execute twice times in your build.
>>> You have to configure a classifier for at least on of them. -> [Help
>>> 1]
>>> 
>>> Am I missing something?
>> 
>> Do you invoke two overlapping phases? E.g., package and install?
> 
> I get the error with 'mvn clean package'
> 
> Gary
> PS: There is also a typo in the error message: maven-source-plugn ->
> maven-source-plugin
> 
>> 
>> 
>> -
>> To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org 
>> 
>> For additional commands, e-mail: dev-h...@maven.apache.org 
>> 
>> 
> 
> -
> To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org 
> 
> For additional commands, e-mail: dev-h...@maven.apache.org 
> 


Re: [maven-source-plugin] 3.3.0 incompatible with 3.2.1

2023-08-15 Thread Gary Gregory
On Tue, Aug 15, 2023 at 12:42 PM Michael Osipov  wrote:
>
> Am 2023-08-15 um 14:57 schrieb Gary Gregory:
> > Hi All,
> >
> > In Commons Parent [1], we want to configure child POMs to build both
> > source and test sources, so we say (among other things):
> >
> >
> >  maven-source-plugin
> >  
> >
> >  create-source-jar
> >  
> >jar-no-fork
> >test-jar-no-fork
> >  
> >
> >  
> >
> >
> > Which appears to no longer work in 3.3.0:
> >
> > [ERROR] Failed to execute goal
> > org.apache.maven.plugins:maven-source-plugin:3.3.0:jar-no-fork
> > (create-source-jar) on project commons-cli: Presumably you have
> > configured maven-source-plugn to execute twice times in your build.
> > You have to configure a classifier for at least on of them. -> [Help
> > 1]
> >
> > Am I missing something?
>
> Do you invoke two overlapping phases? E.g., package and install?

I get the error with 'mvn clean package'

Gary
PS: There is also a typo in the error message: maven-source-plugn ->
maven-source-plugin

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

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



Re: [maven-source-plugin] 3.3.0 incompatible with 3.2.1

2023-08-15 Thread Michael Osipov

Am 2023-08-15 um 14:57 schrieb Gary Gregory:

Hi All,

In Commons Parent [1], we want to configure child POMs to build both
source and test sources, so we say (among other things):

   
 maven-source-plugin
 
   
 create-source-jar
 
   jar-no-fork
   test-jar-no-fork
 
   
 
   

Which appears to no longer work in 3.3.0:

[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-source-plugin:3.3.0:jar-no-fork
(create-source-jar) on project commons-cli: Presumably you have
configured maven-source-plugn to execute twice times in your build.
You have to configure a classifier for at least on of them. -> [Help
1]

Am I missing something?


Do you invoke two overlapping phases? E.g., package and install?


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