Skip to content

Latest commit

 

History

History
39 lines (30 loc) · 1.67 KB

README.md

File metadata and controls

39 lines (30 loc) · 1.67 KB

Build Status

Gradle GitHub Ivy Repo Plugin

Easily resolve GitHub release assets as dependencies in Gradle

Usage

See here how to apply this plugin.

GitHub release assets can be resolved and cached as dependencies by adding an Ivy repository with a custom pattern layout. This plugin adds a new github(USER) method to a Gradle project's repositories block so that this can work with minimal overhead.

Example

If GitHub user foo has a repository bar with a release tagged v1.0, and that release has assets (e.g., bar-1.0.zip) that include an Ivy descriptor (i.e., ivy-1.0.xml), then those assets can be resolved from the URLs

In your Gradle build script, you can apply this plugin and then add a repository like this:

repositories {
    github('foo')
}

Then, you can declare a dependency on bar (for some configuration, e.g., data) like this:

dependencies {
    data group: 'io.github.foo', name: 'bar', version: '1.0'
}

The group must match the organisation in the Ivy descriptor.