read

You will need 2 repositories:

  1. Library code
  2. Maven (where the compiled library will stay and other projects will get)

Clone both repositories and:

  1. In your library gradle file (inside one):
android {  
   lintOptions {  
        abortOnError false  
      }  
    }  
    uploadArchives {  
      repositories.mavenDeployer {  
        repository(url: "file:///<absolute_path_to_maven_repo>")  
        pom.version = "0.5"  
        pom.artifactId = "my_library"  
        pom.groupId = "com.yoursite"  
      }  
    }
}  
  1. Do git push with all the deployed changes to your maven_repo With this settings you will need:
repositories {  
	maven { 
		url 'https://bitbucket.org/<repo_owner>/<repo_name>/raw/master' }  
	}  
	dependecies {  
		compile 'com.yoursite:my_library:0.5@aar'  
  	}  
}

Note: the url is the HTTPS url that bitbucket offers (same for github).

Good luck :)

Source 1 Source 2

Blog Logo

Daniel Gomez Rico


Published

Image

MakinGIANTS

The findings and tips records of an Android-iOS-TheWholeShabang group

Back to Overview