Skip to content
This repository has been archived by the owner on Apr 25, 2024. It is now read-only.

lein-droid doesn't exclude dependencies in ${HOME}/.lein/profile.clj #111

Closed
sakuraiyuta opened this issue Nov 19, 2014 · 4 comments
Closed

Comments

@sakuraiyuta
Copy link

project.clj options :profiles said:

For specifying system-wide attributes Leiningen uses $HOME/.lein/profiles.clj file and its :user profile. It works for Clojure-Android projects as well, except for three attributes: :dependencies, :repl-options and :injections. On many configurations they include dependencies and hooks that are incompatible with Clojure-Android, so they are just ignored by lein-droid.

but, lein droid build looks like gets all of dependencies in ${HOME}/.lein/profiles.clj.

ex) ${HOME}/.lein/profiles.clj:

{:user
  :plugins [[lein-droid "0.3.0-beta4"]]
  :dependencies [[jonase/kibit "0.0.8"]]}

I expect that lein-droid excludes kibit...but lein droid build makes error:

$ lein droid build
...................
Build type: debug, dynamic compilation: enabled, remote REPL: enabled.
...................
Compiling kibit.rules.arithmetic
Exception in thread "main" java.lang.ExceptionInInitializerError
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:274)
...................
Caused by: java.lang.IllegalArgumentException: No matching ctor found for class kibit.rules.util$compile_rule$fn__4914
        at clojure.lang.Reflector.invokeConstructor(Reflector.java:163)
        at clojure.lang.LispReader$EvalReader.invoke(LispReader.java:1053)
...................
Compilation failed.
@alexander-yakushev
Copy link
Member

I forgot to update that part of the docs. In version 0.3.0-x lein-droid no longer messes with the profiles and excludes any dependencies. Please recreate the project using the newest lein-droid version and stick to this documentation https://github.com/clojure-android/lein-droid/wiki/Profiles.

@sakuraiyuta
Copy link
Author

I got it. Thanks documentation update.
I'll try re-generate project.clj using lein droid new, and merge present one.

@alexander-yakushev
Copy link
Member

UPD: No, sorry, still better to regenerate as other things besides project.clj have changed too.

@sakuraiyuta
Copy link
Author

👍

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

No branches or pull requests

2 participants