Menu

#496 Gradle task does not resolve outjars lazily

v4.11
closed-fixed
None
7
2014-08-19
2014-02-04
squiddle
No

The gradle task is resolving injars lazily at task execution time

for outjars the resolution is done in the configuration phase.

The source code states otherwise.

if you compare line 202 of ProGuardTask.java https://sourceforge.net/p/proguard/code/ci/default/tree/src/proguard/gradle/ProGuardTask.java#l202

to the corresponding line 188 for injars the problem seems to be that the outjars line 202 should look like this:

this.outJarFiles.add(outJarFiles);

instead of resolving outJarFiles with the project.files method.

Discussion

  • Eric Lafortune

    Eric Lafortune - 2014-02-05

    Thanks for your report. You're right, this seems to be a mistake. I'll fix it for ProGuard 4.12 beta1. It shouldn't make a difference though, since the outjar generally won't exist in either phase. Did you experience any problems because of it?

     
  • Eric Lafortune

    Eric Lafortune - 2014-02-05
    • assigned_to: Eric Lafortune
    • Priority: 5 --> 7
     
  • squiddle

    squiddle - 2014-02-06

    yes i create the outjar like this

    outjars { jar.archivePath.toString().replace(jar.classifier, 'minified') }

    to have consistent names with the same file name construction rules as the jar task does

     

    Last edit: squiddle 2014-02-06
  • Eric Lafortune

    Eric Lafortune - 2014-04-19
    • status: open --> open-fixed
     
  • Eric Lafortune

    Eric Lafortune - 2014-08-19
    • Status: open-fixed --> closed-fixed
     

Log in to post a comment.