How to add own project to public maven repository?
Asked Answered
C

1

15

I'd like to add my project to public maven repository so that it can be used by community. It doesn't have to be maven central - just any kind of public and free repository for open source code.

How do I do that (in easiest way)?

Cranach answered 30/11, 2011 at 18:47 Comment(4)
I'd like to add that project is hosted on GoogleCode and as far as I know there is no way to do that automatically (from GoogleCode)Cranach
See also #1280970Handsome
Thanks for comment but I'm using Mercurial for my version contoling needs so this SVN solution probably won't workCranach
Ideally you need to deploy to a proper Maven repo. The following link is another option for doing it via google code: thewebsemantic.com/2009/04/11/…Handsome
H
14

Probably 3 ways to do this:

  1. If you have a web server you can simply drop the jar and pom into a directory, eg: yourserver.com/mavenRepo/com/yourcompany/v1.0/yourjar.jar This is the 'quick and dirty' way, but then the public can add yourserver.com/mavenRepo as a repository.
  2. Have an out-facing instance of Nexus or Artifactory
  3. Make the project more official through one of the common open source projects, described in the 'Approved Repository Hosting' and the 'Other Projects' sections of this page.
Hazelhazelnut answered 30/11, 2011 at 18:56 Comment(3)
Thanks for answer. Here's URL to Sonatype guide docs.sonatype.org/display/Repository/…Cranach
@Cranach The link given by you makes 404 error, can you update?Waterway
It's probably here now (you'll also need to check referenced pages as well): central.sonatype.org/pages/ossrh-guide.htmlCranach

© 2022 - 2024 — McMap. All rights reserved.