Jitpack.io: Ability to retain original groupId & artifactId

Created on 21 Dec 2016  ·  2Comments  ·  Source: jitpack/jitpack.io

The need to pick a distinct GA when using jitpack is problematic, since Maven then treats the artifact as unrelated to the “real” one. An example of a problem that you can hit is that the dependency resolution algorithm “prefer nearest” breaks down when there are dependency trails to both the jitpack and regular versions of the same dependency: Maven will include both in the dependency graph, causing mayhem.

Here in https://github.com/jenkinsci/workflow-job-plugin/pull/27 you can see an example of the fragile workaround of excludeing the regular versions. This is onerous enough that I think I would rather go back to deploying timestamped snapshots (obviously only an option if you have upload permission to a relevant repository).

Would it be possible to allow you to keep the original GA and encode the repository information in the version instead? For example, rather than

<dependency>
    <groupId>com.github.jglick</groupId>
    <artifactId>workflow-api-plugin</artifactId>
    <version>ea218b9</version>
</dependency>

I would much rather see

<dependency>
    <groupId>org.jenkins-ci.plugins.workflow</groupId>
    <artifactId>workflow-api</artifactId>
    <version>com.github:jglick:workflow-api-plugin:ea218b9</version>
</dependency>

or even (for better behavior with, e.g., versions:display-dependency-updates)

<dependency>
    <groupId>org.jenkins-ci.plugins.workflow</groupId>
    <artifactId>workflow-api</artifactId>
    <version>2.9-com.github:jglick:workflow-api-plugin:ea218b9-SNAPSHOT</version>
</dependency>

where the dependency is

<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-api</artifactId>
<version>2.9-SNAPSHOT</version>
enhancement

Most helpful comment

Hi, is there some news about this feature?

All 2 comments

Hi, is there some news about this feature?

Hi, any news on this enhancement?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rumatoest picture rumatoest  ·  5Comments

msgilligan picture msgilligan  ·  6Comments

jitpack-io picture jitpack-io  ·  6Comments

cekvenich picture cekvenich  ·  4Comments

vananiev picture vananiev  ·  5Comments