Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No Sources jar Published. Unable to use with GWT libGDX Builds #2

Closed
Barryrowe opened this issue Sep 18, 2016 · 8 comments
Closed

No Sources jar Published. Unable to use with GWT libGDX Builds #2

Barryrowe opened this issue Sep 18, 2016 · 8 comments

Comments

@Barryrowe
Copy link

I started using your fork for a libGDX extension library I'm working on because you had actually published to a repo that I can use in my gradle config.

However, while this works with desktop/android/ios modules for a libGDX project, the GWT module requires source code for all dependencies to compile. I can see in the build that the package step does generate a sources jar, it looks like it just needs to be published whenever a version is published to the repository on jitpack.

@Barryrowe
Copy link
Author

Work around for anyone else that comes across this until a sources jar is published a maven repo. You can add the sources jar from a local build by:

  1. clone this repository

    git clone https://github.com/Arcnor/universal-tween-engine.git
    
  2. Generate a build

    cd universal-tween-engine/java
    ant package
    
  3. In your gradle config add this to the dependencies block of your project that needs the sources jar:

    compile files("../relative/path/to/universal-tween-engine/java/build/api/tween-engine-api-sources.jar")
    
  4. Make sure to add the tween engine as a dependency in your gwt.xml file(s):

    <inherits name='aurelienribon.tweenengine' />
    

@Arcnor Arcnor closed this as completed in 874d3cc Sep 20, 2016
@Arcnor
Copy link
Owner

Arcnor commented Sep 20, 2016

The problem was that no sources jar was being generated (I'm not sure why you saw it, maybe you were testing different things and something got cached?)

In any case, you can probably test this by changing your imports to:

dependencies {
  compile 'com.github.Arcnor:universal-tween-engine:-SNAPSHOT'
}

This won't work with Maven, so hopefully you're using Gradle :).

If it does, I'll tag this as 6.4.4 and you'll be able to change -SNAPSHOT with 6.4.4 instead, which might be cleaner :).

@Barryrowe
Copy link
Author

I'll give this a shot tonight.

Just curious, do you mean using:-SNAPSHOT:sources or are you bundling the sources jar into the distribution jar?

@Arcnor
Copy link
Owner

Arcnor commented Sep 20, 2016

I meant just changing the version of your dependency to -SNAPSHOT should work. Sources are now part of the published archives.

Also, I forgot to say it before, but the first time you do this it will take up to 10-15 minutes, so please be patient, Gradle hasn't hang up :D

@Barryrowe
Copy link
Author

Sorry for the delay. I just attempted this, and it does look like both jars are published. Using the following I was able to include the sources jar to my GWT build:

compile 'com.github.Arcnor:universal-tween-engine:-SNAPSHOT:sources'

@Arcnor
Copy link
Owner

Arcnor commented Sep 22, 2016

Awesome, I'll tag this as 6.4.4 then, and you can use that instead of -SNAPSHOT :)

@Barryrowe
Copy link
Author

Perfect thanks! Does this include any other changes? Thanks for taking the effort to publish this!

FYI, I came across this on the original repository the other day, in case you'd like to share anything with the original author on publishing. I provided some input but it's unclear if they'll be making time to work on it again, or if they'd want to pull your stuff in.

AurelienRibon#7

@Arcnor
Copy link
Owner

Arcnor commented Sep 22, 2016

As far as I remember, I didn't include any other changes here, no. But the git history will tell better than me, it's been ages since I used this project :D.

I'll try to chime in on that issue. He can just pull what I have, probably, and it will just work (that's the magic of Jitpack :D).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants