2

I have a project that is hosted on github. Now what I want is that just by including a few lines like these, anyone is able to use my library in their maven project.

>    <dependency>
>       <groupId>org.anahata</groupId>
>       <artifactId>anahata-core</artifactId>
>       <version>1.0</version>    
     </dependency>

I am new to maven, so please tell me the exact steps. Can it be hosted from github itself?

Apurv
  • 4,458
  • 2
  • 21
  • 31

2 Answers2

2

You can have your project hosted in the Maven Central Repository following the tips posted here, here and here. See also this question and this one.

Edit: Also Sonatype's guide as suggested by khmarbaise (it is referred to by the guides above).

Community
  • 1
  • 1
Fernando Correia
  • 21,803
  • 13
  • 83
  • 116
1

Not to miss the guide of Sonatype:

https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide

khmarbaise
  • 92,914
  • 28
  • 189
  • 235