Skip to content

--package not working with Gradle 5.0 #197

Closed

Description

@abelsromero

Running the package option with gradle 5.0 installed causes it to fail with the underlying gradle message.

Gradle does not allow passing null for the configuration action for CopySpec.from()

Note that the message was captured debugging.

With gradle 4.10.2, it worked fine.

Activity

  1. abelsromero commented on Dec 1, 2018

    @abelsromero
    Author

    Seems to be a known issue with no quick solution danthegoodman/gradle-capsule-plugin#38

  2. holgerbrandl commented on Dec 4, 2018

    @holgerbrandl
    Collaborator

    Thanks @abelsromero for the pointer. So let's hope that they fix it soon. Not sure what to do about it on the kscript side.

  3. abelsromero commented on Dec 4, 2018

    @abelsromero
    Author

    Not sure what to do about it on the kscript side.

    To keep current implementation we could "reverse engineer" the gradle plugin and directly use the capsule API.
    Or just build it the package in another way, I guess that so long as we add a bootstrap script to the path and have the jars somewhere we keep the feature the same from a user stand point. It would be nice also because that way we remove the dependency from gradle.

  4. holgerbrandl commented on Dec 6, 2018

    @holgerbrandl
    Collaborator

    I think the best approach would be to figure out and implement a PR for the gradle-capsule-plugin which fixes the problem.

  5. f-meloni commented on Dec 11, 2018

    @f-meloni

    Apparently there is already a PR for that
    danthegoodman/gradle-capsule-plugin#39
    But the problem is that gradle-capsule-plugin is no longer maintained, then could be worth evaluate remove it as dependency to avoid this kind of problems in the future.
    Or maybe just fork it

  6. holgerbrandl commented on Dec 12, 2018

    @holgerbrandl
    Collaborator

    danthegoodman/gradle-capsule-plugin#39 seems to work only with gradle 5 and not with older gradles, otherwise I'd just fork the PR and push it to jcenter as a quickfix. But this option does not seems on the table, because at least gradle 4 should be supported by the plugin.

    For sure the best solution would be to implement packaging in-process without calling an external tool. This would also remove the dependency on the capsule-gradle-plugin. Maybe capsule could be called programmatically? I would be very thankful for any help on such a feature.

    Alternatively with the new bootstrap header support contributed with #199 we could also think about dropping --packaging entirely? IMHO both are a bit too different, so it may be nice to maintain both packaging modes separately.

  7. gianluz commented on Jan 8, 2019

    @gianluz
    Contributor
  8. holgerbrandl commented on Jan 12, 2019

    @holgerbrandl
    Collaborator

    @gianluz Is there a new version of the gradle-capsule-plugin with these PRs merged in already which we could use instead to fix this kscript packaging?

  9. gianluz commented on Jan 23, 2019

    @gianluz
    Contributor

    i forked gradle-capsule and opened this PR gianluz/gradle-capsule-plugin#1

  10. gianluz commented on Jan 23, 2019

    @gianluz
    Contributor

    do you want to use this fork?

  11. holgerbrandl commented on Jan 23, 2019

    @holgerbrandl
    Collaborator

    As soon as it's published as corrected artifact on jcenter (or similar) yes.

  12. gianluz commented on Feb 2, 2019

    @gianluz
    Contributor

    I have published the new plugin, i'm just awaiting for approval, after that i'll open a PR here to fix the problem 😄

  13. f-meloni commented on Feb 6, 2019

    @f-meloni

    @holgerbrandl Given #210 is merged, if you can please make a release, then I can check if the problem is solved :) 🎉 🚀

  14. aartiPl commented on Jul 9, 2022

    @aartiPl
    Collaborator

    There is a replacement of the capsule plugin in branch kscript_4.1. I am closing this ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions