Adds a :classifiers project key that takes a map from classifier keyword to
profile map.
:classifiers {:tests {:source-paths ^:replace ["test"]
:resource-paths ^:replace []}}
Enforces a nREPL dependency and a clojure-complete dependency for the :repl
profile. Previously, the first found :repl profile from
`project.clj`-`profiles.clj`-default was returned and merged into the real
profile. Now all :repl profiles that are found are merged into the active
profile.
The dependencies are tagged with the ^:displace tag, and as such will be
discarded if a collision occurs.
The changes made `repl-profile-in-project` fail as it did not contain
`leiningen.core.project/empty-dependencies`, which has a :reduce tag in its
metadata for handling dependency merging. The dependency merger expands the
version to its url, hence the change to a url map.
Also removed a TODO from the file, fixed by 27fe39d.
This is accomplished with the :reduce metadata, which specifies the
reduce function to use when merging. This allows us to merge
dependencies and repositories deeply like other structures. Note that
dependencies are transformed into a map before they are merged and then
transformed back into a vector.
Also change the way that collections are merged. They used to be merged
by taking the right collection and prepending it to the left collection.
This behavior was needed for :*-paths in defproject, but it is not an
obvious default. Now, the default is to append the right collection, but
the :prepend metadata can be used to tell meta-merge to prepend instead.
By default, :source-paths, :resource-paths and :test-paths have :prepend
set to true.
The help task will first look for static help under
'leiningen/help/task-subtask', then for a function name 'help-subtask' in the
subtask's namespace, then a docstring on the subtask function. For the latter
two options, the arglists are also printed.
More specific metadata wins, e.g. deftest trumps its namespace.
Also tweaked the tests a bit so that actual/expected results are now
shown in the output.
Showing every failed repo lookup is bad for users.
They see the failure and get confused.
Hook up a custom listener that has the following behavior:
1. success -> print out artifact name, size, and repository name
2. failure -> ignore unless it is the last repo, then print out failure
message with artifact name.
Fixes#610.
Reading a project should be side affect free. init-project modifies the current
classloader (and possible installs a new context classloader), so should not be
part of leiningen.core.project/read.
We intentionally don't try to support every single Lein 1 option because there is no way
to do everything Ant javac task can do with JDK's javac API. And it's also not necessary
because many of those features are very opinionated at best.