0

I have a github repository and I want to make it as a gradle dependency so that anyone can add in his build gradle.

can anyone help me?Thanks in advance.

Rakesh kushwaha
  • 709
  • 1
  • 10
  • 22
  • Possible duplicate of [Create a gradle dependency to import from git](https://stackoverflow.com/questions/33053779/create-a-gradle-dependency-to-import-from-git) – LazerBanana Aug 02 '17 at 11:05

2 Answers2

0

You need to upload it to jcenter or Maven Central

you can read how to do so here


or the easiest way you can just use jitpack

as noted in the comments this question is a duplicate of https://stackoverflow.com/a/33053965/3998402

humazed
  • 74,687
  • 32
  • 99
  • 138
0

I personally thing that jitpack is a hack and shouldn't be used in the real world.

The simplest option is to sign up to bintray and use the bintray gradle plugin to deploy your artifacts there.

You can also deploy to maven central which can be more difficult than bintray. For instance maven central requires that you "own" the domain for your group id (many people use their github domain as their group id). Maven central also requires much more info including authors and other fields.

You can also host a maven repo on github which I've done myself here. This relies on the https://raw.github.com URL structure to serve up the jars as binary.

lance-java
  • 25,497
  • 4
  • 59
  • 101