Commit graph

2876 commits

Author SHA1 Message Date
Michael Hanson
f1b7365556 Use find . instead of tree in the tutorial
`find` is more universal than `tree`.

Fixes #892.
2013-01-09 20:07:58 -08:00
Phil Hagelberg
bfc24c3486 Merge pull request #911 from hugoduncan/feature/central-is-release-only
Disable snapshots from maven central
2013-01-09 14:07:25 -08:00
Hugo Duncan
eb58efca7d Disable snapshots from maven central 2013-01-09 17:04:40 -05:00
Phil Hagelberg
6f77bd1dbe Add debug logging to javac. 2013-01-08 10:20:32 -08:00
Phil Hagelberg
bfff08f5dd Merge pull request #910 from trevor/patch-1
No tabs
2013-01-08 09:24:12 -08:00
Trevor Wennblom
496f1352a1 No tabs
:)
2013-01-08 09:57:56 -06:00
Jean Niklas L'orange
ef3641c172 Add a repo test case which actually merges repositories. 2013-01-07 21:48:03 +01:00
Jean Niklas L'orange
0bb1cc42bf Avoid crash in lein.bat when path contain spaces. Fixes #907. 2013-01-07 21:00:23 +01:00
Jean Niklas L'orange
88dfec8daf Add tests to ensure that repository merging works as intended. 2013-01-07 20:42:19 +01:00
Jean Niklas L'orange
4c1320255e Normalize repositories in project map before merging. Fixes #858. 2013-01-07 02:54:46 +01:00
Phil Hagelberg
3d3fb9cdb2 Clarify the exit docstring. 2013-01-02 22:32:30 -08:00
Phil Hagelberg
da3b3e13f2 No tabs! 2013-01-02 22:32:15 -08:00
Phil Hagelberg
0d69412db6 Move contributing guidelines into their own file. 2013-01-02 22:32:07 -08:00
Michael Klishin
18ed0590ff Merge pull request #902 from hyPiRion/uberjar-compile-after-aot-calculations
Make jar accept alternative main class
2013-01-02 14:36:49 -08:00
Jean Niklas L'orange
ce2913062f Don't conj :main during uberjar if :aot is :all.
When :aot is :all, don't conjoin the :main value to :aot, as this will result in
an error.
2013-01-02 19:48:29 +01:00
Jean Niklas L'orange
98cc22927f Make jar accept alt. main class as arg. Fixes #897 and fixes #899.
By having jar accepting an alternative main class, uberjar can call jar with an
additional parameter and uberjar's alternative main class won't be ignored. This
fixes #897. In addition, as jar is now responsible for adding main to :aot, the
main class will now actually be compiled. This fixes #899.
2013-01-02 19:48:25 +01:00
Colin Jones
e01a1980af Bump reply again for more sjacket fixes 2012-12-29 16:54:27 -06:00
Colin Jones
9f628786eb Bump reply version 2012-12-28 21:50:05 -06:00
Phil Hagelberg
712ac9a017 Exclusion to pacify lein-pedantic. 2012-12-28 12:00:19 -08:00
Jean Niklas L'orange
511ba8eed7 Fix typo in sample.project 2012-12-28 05:00:44 +01:00
Jean Niklas L'orange
6280b73da0 Enforce nREPL dependencies in :repl profile. Fixes #893.
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.
2012-12-28 04:56:27 +01:00
Jean Niklas L'orange
27fe39d618 Fix ^:displace and ^:replace handling in meta-merge
An object with the metadata flag `:displace` set signals that, if a merge
conflict appears, this object is to be discarded. Likewise, `^:replace` signals
that this object should be kept in a merge conflict.

However, previous functionality only tested if the right element had the
`:replace` flag, or if the left element had the `:displace` flag. This commit
resolves this by checking whether the left element has a `:replace` flag and the
right element has a `:displace` flag, and handles accordingly to the semantics
explained in the previous paragraph.

Whenever two elements where both has the `:displace` flag is merged, the
leftmost is picked, and their metadata is merged. Likewise for the `:replace`
flag. The elements will not lose their `:displace` and `:replace` flags, as they
have not really been preferred over another element.

The `nil?` tests have been placed at the top to reflect that nil is the lack of
a value, not a value itself. As such, elements will not be "preferred" or
"discarded" over nil/nothing.
2012-12-28 04:28:34 +01:00
Michael Klishin
9bb4a5acb3 Merge pull request #894 from fbernier/patch-1
Fix deploy link in tutorial
2012-12-27 17:48:25 -08:00
François Bernier
296653e8f6 Fix deploy link in tutorial 2012-12-27 20:45:31 -05:00
Phil Hagelberg
034f94efc3 Bump default search page size up to 50. 2012-12-26 10:21:42 -08:00
Phil Hagelberg
efce0f11f3 Fix bizarre pom indentation. 2012-12-26 10:21:23 -08:00
Phil Hagelberg
98afd7ed44 Whitelist certain keys into jar/uberjar creation. Fixes #770. 2012-12-26 10:20:24 -08:00
Phil Hagelberg
f92f677eb7 Disable a test that requires Java 7. 2012-12-26 10:12:03 -08:00
Phil Hagelberg
799bf696d3 Fix classpath test. 2012-12-26 10:07:57 -08:00
Phil Hagelberg
b4cc0f9dba Rename :post-preview selector to :disabled. 2012-12-26 10:07:51 -08:00
Phil Hagelberg
c43951c9d5 Better explanation of :pom-addition, a few more env vars in sample. 2012-12-26 09:33:36 -08:00
Phil Hagelberg
335cd739db Merge pull request #889 from jaceklaskowski/patch-3
Squashing typos in the plugin section of README.md
2012-12-21 09:09:40 -08:00
Jacek Laskowski
a165c8c06e Update README.md
Squashing typos in the plugin section
2012-12-21 17:27:03 +01:00
Phil Hagelberg
1e4180148f Update lein-pkg. 2012-12-19 09:40:39 -08:00
Phil Hagelberg
d736a52588 Merge pull request #888 from hyPiRion/skip-pom-git-revision-if-empty-git-repo
Skip git revision in pom if empty git repo. Fixes #887.
2012-12-17 13:52:37 -08:00
Jean Niklas L'orange
23da9257a2 Skip git revision in pom.xml if empty git repo.
Tests if the git ref path exists before slurping the SHA from it. If it does not
exist, return nil instead of throwing an error. Also remove empty references to
the SHA where they may occur.
2012-12-17 20:20:22 +01:00
Nelson Morris
723671b607 Use aether data to figure out repository id for listener output
For "important" events, aether gives us enough info to figure
out which repo it is happening from.  Lets use it instead
of trying to match from project data.

Previously matching from the project data would be incorrect
and output failures or not output anything for transative repos.
2012-12-15 13:16:07 -06:00
Nelson Morris
c07259f875 Print checksum mismatch message
Previously the output for downloading files would just say "failed to find".
Instead output the fact checksums were invalid, and from which repository.
2012-12-15 11:13:00 -06:00
Phil Hagelberg
83d23e3a18 FAQ clarification around classpathy things and repos. 2012-12-14 14:45:30 -08:00
Phil Hagelberg
9cceba88e2 Stop using prefix lists in javac's :require. 2012-12-14 14:44:58 -08:00
Phil Hagelberg
b15a1188db Upgrade to lein-newnew 0.3.6. Fixes #865. 2012-12-14 14:42:24 -08:00
Phil Hagelberg
3a1f84f993 Merge pull request #886 from hyPiRion/run-javac-in-subprocess
Make javac run in a subprocess. Fixes #809.
2012-12-14 14:42:05 -08:00
Jean Niklas L'orange
d38ecd353b Check compiler existence within javac subprocess.
Also added ^:displace to avoid adding multiple clojure-versions onto the
classpath, and fully expanded non-`clojure.core` namespaces.
2012-12-14 14:49:53 +01:00
Jean Niklas L'orange
377a98f45e Make javac run in a subprocess. Fixes #809.
If we're not making javac run in a subprocess, libraries the project
depends on which leiningen has another version of will clash. This is
because leiningen append its standalone to java's bootclasspath, which
makes the ToolProvider add these classpaths automatically into the java
compiler it returns. By starting a subprocess without leiningen added to
the bootclasspath, we avoid this library clashing.

UI changes as a result of this patch: Whenever javac fails, the task one
wanted to run will be responsible for aborting Leiningen, whereas javac
did this itself when it discovered that the compilation failed. As we're
running in a subprocess, an abort message such as

    Uberjar aborting because jar/compilation failed: Subprocess failed

will appear, though this will only be appended to the javac error
message and the "Compilation of Java sources (lein javac) failed."
message.

This commit also adds the overhead of starting a subprocess when one
have to compile java sources, but it will not start one if no
.class-files are outdated/not existing.

Not tested on Windows.
2012-12-13 18:37:45 +01:00
Phil Hagelberg
b4558ec274 Merge pull request #883 from hyPiRion/fix-with-profile-recursive-aliases
Removes run task aliases within metadata. fix #882
2012-12-10 20:20:40 -08:00
Jean Niklas L'orange
d6ba16b9da Removes run task aliases within metadata. fix #882
Removes the task to be run residing within a project's metadata (inside
:without-profiles) in addition to the original map, in order to prevent
"with-profile" from reviving already used aliases.
2012-12-11 02:27:45 +01:00
Phil Hagelberg
2b004681f9 Merge pull request #881 from hyPiRion/alias-java-opts-to-jvm-opts
Add :java-opts as an alias for :jvm-opts
2012-12-09 20:38:10 -08:00
Jean Niklas L'orange
493adefe34 Add :java-opts as an alias for :jvm-opts 2012-12-09 19:50:34 +01:00
Anthony Grimes
5c59d28aa9 Factor out selected-namespaces code to prevent walk-off-the-screenage. 2012-12-07 17:44:31 -06:00
Anthony Grimes
ba9e56f259 Add capability for selectors to be two functions (one checks the ns, one the vars)
This makes it so that a selector such as :only can prevent unnecessary loading
of namespaces that they aren't going to work on. It is a way for a selector
that knows which namespaces it will touch by the selector's arguments and the
namespace names themselves to not have to load all namespaces.

This commit also fixes a bug introduced by a recent pull request where
'namespaces' could not be resolved. Per discussion with technomancy, provided a
default test selector *always*.
2012-12-07 17:44:31 -06:00