Skip to content

Loading…

Deal with recent lein2 backwards incompatible changes #122

Closed
emezeske opened this Issue · 5 comments

2 participants

@emezeske
Owner

Running cljsbuild commands with lein2 results in messages like the following:

WARNING: using numeric exit values in plugins is deprecated.
Plugins should use leiningen.core.main/abort instead.
Support for this will be removed before the stable 2.0.0 release.

The way that plugins are supposed to exit has changed in the latest preview release.

@emezeske
Owner

I fixed things so that things are no longer broken for lein1, which requires plugins to return numeric exit codes.

However, task chaining is broken in lein2, because the plugin actually exits the process, even upon success. I don't know if this is a design problem with the new leiningen.core.main/exit and leiningen.core.main/abort functions, or what, but it's a pretty significant problem.

@emezeske
Owner

Sigh... All of the hook functions are broken by this lein2 change. :(

@emezeske
Owner

Regarding task chaining being broken, I think it's because the plugin should not call leiningen.core.main/exit if it's successful -- it should just return nil.

@emezeske
Owner

Okay, I think I have exiting, chaining, and hooks all working in both lein1 and lein2 now.

@emezeske emezeske closed this
@semperos

Thanks for providing a proper fix against my previous pull request :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.