Issue Details (XML | Word | Printable)

Key: SPR-2704
Type: Task Task
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Ben Hale
Reporter: Ben Hale
Votes: 28
Watchers: 23
Operations

If you were logged in you would be able to see more operations.
Spring Framework

Create and upload Maven Source and Javadoc Bundles for Spring 2.0

Created: 11/Oct/06 04:51 PM   Updated: 21/Aug/07 07:49 PM
Component/s: SpringCORE
Affects Version/s: 2.0 final
Fix Version/s: 2.1 M3

Time Tracking:
Not Specified

File Attachments: 1. Text File SPR-2704.patch (20 kB)

Issue Links:
Depends
 
Duplicate
 


 Description  « Hide
Create and upload Maven Source and Javadoc Bundles for Spring 2.0 per user request

 All   Comments   Work Log   Change History   FishEye   Builds      Sort Order: Ascending order - Click to sort in descending order
nicolas de loof added a comment - 25/Oct/06 09:52 AM
Just for info, you can get them from my custom repo : http://ndeloof.free.fr/maven2

I also asked Carlos Sanchez (from Maven team) to upload sources & javadocs
http://jira.codehaus.org/browse/MAVENUPLOAD-1192

Cameron Braid added a comment - 12/Nov/06 05:24 AM
I think this is a great idea. I noticed that the spring-2.0-sources.jar is in http://repo1.maven.org/maven2/org/springframework/spring/2.0/ but the source modules for the separate modules aren't.

Kohsuke Kawaguchi added a comment - 17/Nov/06 03:50 PM
My +1 on this.

Cameron Braid added a comment - 17/Nov/06 06:43 PM
I found someone else who has these source jars in a maven 2 repository.

http://ndeloof.free.fr/maven2/

nicolas de loof added a comment - 20/Nov/06 02:50 AM
This patch adds two Ant targets :
- "module-source-jars" to build Spring modules source bundles
- "module-javadoc-jars" to build Spring modules javadocs bundles

This patch as the disadvantage that the compiler includes/excludes must be duplicated in source and javadoc targets.

Aaron Digulla added a comment - 22/Nov/06 04:24 AM
:-( It duplicates much more than that.

Basically, it's enough to add "source:jar" to the mvn call. I tried to force maven to add this to the build using this XML:

                <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
                 <artifactId>maven-source-plugin</artifactId>
                 <version>2.0.1</version>
                 <configuration>
                 <attach>true</attach>
                 </configuration>
                 <executions>
                 <execution>
                 <goals>
                 <goal>jar</goal>
                 </goals>
                 </execution>
                 </executions>
                </plugin>

but it doesn't work reliably (a.k.a. "not at all"). But if you can run additional ant targets during the build, I suggest to use it to run mvn source:jar instead of building the sources manually.

Aaron Digulla added a comment - 22/Nov/06 06:36 AM
I've opened http://jira.codehaus.org/browse/MSOURCES-11 in Maven to fix this.

Currently, you cannot configure the source plugin in the parent POM of your modules. You have to configure it in each module POM.

As a workaround, I would prefer this solution (copying the four lines with the plugin config into each pom.xml) instead of this huge build.xml.

Baerrach bonDierne added a comment - 14/Jan/07 05:22 PM
You can configure source plugin at the parent project, none of my modules define anything to do with the source plugin and all modules correctly create the source.jar.

I am successfully doing that via
{noformat}
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
{noformat}

Aaron Digulla added a comment - 15/Jan/07 04:09 AM
Interesting, this doesn't work for me. As soon as I put this in the parent POM, no source is generated anymore.

Which version of the source plugin are you using? What version of maven? Can you please add your comments to bug MSOURCES-11 ?

Tomislav Stojcevich added a comment - 10/May/07 11:33 AM
The command line switch -DperformRelease=true should create sources and javadoc artifacts in addition to the main artifact for each project.

Dimitry Voytenko added a comment - 31/May/07 12:52 PM
All 2.x versions are w/o sources and javadocs.

Ben Hale added a comment - 01/Jun/07 06:48 AM
We're going to skip the Javadoc bundles for now as they appear to be the least useful and the hardest to create.

Gregory Kick added a comment - 21/Aug/07 06:40 PM
Why is this marked fixed? http://mirrors.ibiblio.org/pub/mirrors/maven2/org/springframework/spring-core/2.0.6/ definitely does not have sources.

Ismael Juma added a comment - 21/Aug/07 07:14 PM
It says "Fix Version/s: 2.1 M3", so you need to use a 2.1 build to benefit from it.

Gregory Kick added a comment - 21/Aug/07 07:49 PM
oh, that's odd... why wouldn't somebody just create and upload the source bundles for previous versions? we're not even talking about a bug, this is a one-time maintenance task.