I'm new to working with Java and have questions regarding the Maven Central Repository. I am much more familiar with Python and PyPI, so I will provide the equivalent in PyPI that I would like to find in Maven.
How can I find the source code for the artifacts in Maven Central? Typically, I see the JAR file and prefer not to decompile these files. Typically, PyPI packages have the source file type in the "Download files" tab.
How can I find the associated project URL to a maven artifact? In PyPI, the package page has a set of project links and generally provides a repository link (e.g., Github, Bitbucket)
How can I identify open-source projects in the Maven central repository? The license for PyPI projects is tagged directly in the meta-reference on the sidebar of a project page.
I appreciate any insight into these questions. Thanks!
CodePudding user response:
When a distributor decides to provide them, you can find
-sources.jar
and a-javadoc.jar
files in the artifacts folder. (common IDE's are aware of that&provide buttons/menus, "Maven>Download XXX";)- like e.g. here.
- Artifact javadoc (for the sophisticated ones,
javadoc
andsources
refers to the (common) "classifier" of the artifact). - how (easy) to produce them.
In the pom:
project.url
tag provides:The project's home page.
project.scm
element provides (should provide!) "source control" related (multiple) urls (read-only, contributer, public-browsing).besides that many other things(and sub-things) can have url in a maven project/pom (distributionManagement(i.e repository), organisation, developer,...).
project.licenses
element!
You can be sure to find all of three (- four) in all (at least latest) artifacts in maven central, due to:
Their Publishing Requirements!;