Commit graph

526 commits

Author SHA1 Message Date
david.powell
4ef01fcaa9 always process trampolines, even when used in aliases and higher-order tasks
remove unused leiningen.trampoline-file system property
2013-03-18 16:02:24 +00:00
david.powell
f3e71aa03f ensure only one set of quotes around java command in trampolines 2013-03-18 15:16:03 +00:00
Phil Hagelberg
78889f1c68 Include LEIN_VERSION in LEIN_FAST_TRAMPOLINE files.
Fixes #962.
2013-03-16 20:47:52 -07:00
Michael Klishin
a91f40d3e1 Merge pull request #1066 from djpowell/lein-bat-fixes
lein.bat fixes
2013-03-15 15:15:40 -07:00
David Powell
f3059d4d25 Simplify handling of LEIN_JAVA_CMD to support parens in paths, such as with "Program Files (x86)" 2013-03-15 20:58:56 +00:00
David Powell
8df3d12ef8 Add back wget and curl support as a fallback for users without powershell. 2013-03-15 20:58:46 +00:00
Phil Hagelberg
e6de716766 Point people to the right place for bootstrapping instructions. 2013-03-14 10:46:55 -07:00
megri
fb1db2cec4 added support for windows/msys 2013-03-12 23:14:39 +01:00
Phil Hagelberg
c6e95593c4 Allow Leiningen checkout to be bootstrapped from 2.x.
Fixes #958.
2013-02-28 17:12:51 -08:00
Phil Hagelberg
ff0f5a6d04 Workaround for :test-selectors and #878.
Gotta love how quote silently discards metadata wooooo.
2013-02-26 11:57:50 -08:00
Phil Hagelberg
66ed4818ec Replace curl/wget usage in lein.bat with powershell.
Addresses #1007.
2013-02-26 10:38:37 -08:00
Phil Hagelberg
af7d5aaffd Improve boot time by limiting tiered compilation. 2013-02-12 09:54:25 -08:00
David Cohen
d7f05cf004 adding message to set HTTP_PROXY and HTTPS_PROXY for those behind a firewall 2013-02-05 20:17:14 -05:00
Gabriel Horner
0a7b974fdc point to correct docs for a local lein checkout 2013-01-29 22:15:33 -05:00
Phil Hagelberg
3391fd8445 Add download log parsing code.
[ci skip]
2013-01-21 20:43:41 -08:00
Phil Hagelberg
be4ec8c81e Bump to 2.1.0-SNAPSHOT. 2013-01-19 20:39:17 -08:00
Phil Hagelberg
0cd13d8cdb Release 2.0.0. 2013-01-19 20:07:46 -08:00
Phil Hagelberg
01e6c953c3 News and FAQ about implicit repl deps.
[ci skip]
2013-01-19 15:25:45 -08:00
Phil Hagelberg
6e42ceea19 Clarify wording of checkout dependencies in tutorial. 2013-01-17 11:47:25 -08:00
Jack Moffitt
eb5ba65f90 Add bin/lein-pkg to the list of files that get version substitutions.
Currently lein-pkg is forgotten about, which means it is always pointing to
the 2.0.0-SNAPSHOT version. This means packagers much edit this file
themselves.
2013-01-16 22:04:47 -07:00
Jean Niklas L'orange
e5511fe516 Back to 2.0.0-SNAPSHOT. 2013-01-13 10:38:54 +01:00
Phil Hagelberg
99f0ed7069 Release 2.0.0-RC2 2013-01-12 17:03:18 -08:00
Phil Hagelberg
829046af7f Fix upgrade command. 2013-01-11 11:06:09 -08:00
Phil Hagelberg
eb15a82e12 Back to 2.0.0-SNAPSHOT. 2013-01-10 16:59:36 -08:00
Phil Hagelberg
1e309c1a52 Release 2.0.0-RC1 2013-01-10 16:45:09 -08:00
Phil Hagelberg
871b1c0b61 Move downloads to S3 bucket. Fixes #885. 2013-01-10 11:57:24 -08: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
Phil Hagelberg
da3b3e13f2 No tabs! 2013-01-02 22:32:15 -08:00
Phil Hagelberg
1e4180148f Update lein-pkg. 2012-12-19 09:40:39 -08:00
Allen Rohner
ec8b8fab34 export $SCRIPT as leiningen.script 2012-12-01 18:51:15 -08:00
Shantanu Kumar
bd781857c2 omit redundant :no_upgrde snippet 2012-11-21 22:57:43 +05:30
Shantanu Kumar
214e464cec add upgrade support to lein.bat master 2012-11-21 22:28:01 +05:30
Phil Hagelberg
2973d99652 Check Clojars releases repository instead of classic. Fixes #241. 2012-11-14 12:45:34 -08:00
Phil Hagelberg
4c19f1ee27 Fix font-lock in bin/lein 2012-11-12 14:40:23 -08:00
Phil Hagelberg
13bb1dc37e Allow for $LEIN_TRAMPOLINE_WARMUP.
[ci skip]
2012-11-03 09:54:35 -07:00
Bruce Adams
cbe087d489 Finish getting path quoting right for boot classpath #828 2012-10-27 12:57:39 -04:00
AtKaaZ
5a57fecf8a make trampoline work on windows
applied the same fix that preview branch had
ie. passing the trampoline file like this:
 -Dleiningen.trampoline-file="%TRAMPOLINE_FILE%" ^
2012-10-26 10:54:53 +02:00
Bruce Adams
c9d271c62b Quote file paths: may contain spaces #828 2012-10-25 22:43:31 -04:00
AtKaaZ
f95a9ffba8 bring back lein.bat from LF to CRLF 2012-10-26 02:11:14 +02:00
AtKaaZ
6e237a8a64 fix for previous commit to allow spaces in folder names
ie. the passed path to -Dclojure.compile.path= should be inside
double quotes
2012-10-26 02:08:05 +02:00
AtKaaZ
898aefb89c Pass default clojure.compile.path just like the bash script does
should fix cases where uses of lein.bat 
would cause the use of /classes/ folder instead of /target/classes/
which resulted in some classes not being found
ie. when compiling leiningen project from source
2012-10-26 01:43:15 +02:00
Phil Hagelberg
ff0e95baf0 Debug output in apply-task. 2012-10-04 09:36:21 -07:00
Justin Balthrop
48bea66ea0 use -classpath instead of -cp so that jdb can be used for :java-cmd 2012-09-27 11:22:03 -07:00
Juergen Hoetzel
8f9c246f14 code reuse: context specific CLASSPATH is used checkout and non-checkout 2012-09-26 20:34:27 +02:00
Juergen Hoetzel
26af2db2b7 use bash helper function add_path to setup classpath
instead of conditionally (cywin/unix) constructing the classpath using
bash assignment.
2012-09-26 20:14:41 +02:00
Juergen Hoetzel
e0398e0819 Add bash function add_path for (class)path setup 2012-09-26 19:48:17 +02:00
Michael Klishin
67726053e5 Merge pull request #783 from StevenBorrelli/patch-1
Fix typos in lein script for download_failed_message
2012-09-14 10:48:59 -07:00
StevenBorrelli
9690f8de65 Fix typos in lein script for download_failed_message
Change downoad_failed_message to download_failed_message
Add endquote to error message for curl HTTP_CLIENT.
2012-09-14 12:46:13 -05:00
basicsensei
a1bc1f56cc move setlocal first to prevent leaking it to parent shell in win7/xp
However on win7 though (but not on winxp) all set variables inside
script will be leaked if the script fails within another setlocal ie. 
set JAVA_CMD="ja"va"
lein
set
Will show LEIN_HOME, LEIN_JAR and ORIGINAL_PWD remained set.

The following .bat will prove the point:
@echo on
setLocal EnableExtensions EnableDelayedExpansion
set xxx="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

rem comment the following line to prevent xxx to leak into parent shell:
setlocal
rem the below will make script fail(just type "set" to see it leaked):
if x == '

echo not reached!
2012-09-13 09:48:29 +02:00
basicsensei
3b5feb5393 use LEIN_JAVA_CMD in lein.bat just as in the bash script
just as @technomancy said in #774
if LEIN_JAVA_CMD is not set it will fall back to JAVA_CMD which in turn
if it's not set it will fall back to just "java" (without dbl.quotes)
2012-09-13 02:48:26 +02:00
Phil Hagelberg
a1d4a0fb79 Don't use fast trampolines outside a project. Fixes #777. 2012-09-11 10:30:16 -07:00
basicsensei
1ac8eac0cc fix for when JAVA_CMD is set to path containing double quotes
addresses #774
script will still fail if it contains characters like >, <, |, & or even
parentheses or an even number of double quotes
ie. this will work:
set JAVA_CMD="c:\program"" f""iles\java\jdk1."7.0_0"5\bin\java.exe"
lein javac
2012-09-11 15:47:22 +02:00
Justin Balthrop
35a01e64c8 work with drip-stable, et al 2012-08-31 16:17:49 -07:00
Justin Balthrop
a92fa36028 add DRIP_INIT so lein will be faster when running with decaf 2012-08-29 15:36:06 -07:00
Justin Balthrop
30a6643fcd Fix trampoline file to work with Drip
Read the TRAMPOLINE_FILE environment variable instead of putting it
in a system property. Drip looks up pre-spun JVMs using a hash of the
command-line arguments, so putting the trampoline file in a system
property causes it to start a new spare JVM for every lein invocation.
2012-08-29 15:36:01 -07:00
Phil Hagelberg
a29bc0c248 Echo $LEIN_JAR path in self-install. Fixes #753. 2012-08-28 12:01:37 -07:00
Adirelle
7c927202b9 Have lein.bat use local .lein-classpath.
This should fix issue #718.
2012-08-26 21:40:21 +03:00
Phil Hagelberg
c08d4aa2dd Stupid bash typo. 2012-08-25 18:55:02 -07:00
Phil Hagelberg
f633c90164 Back to 2.0.0-SNAPSHOT. Next release will be RC1, for reals. 2012-08-25 18:41:32 -07:00
Phil Hagelberg
3b1924e538 Release 2.0.0-preview10. 2012-08-25 16:49:21 -07:00
Phil Hagelberg
59303f8101 Consistently explain how to set insecure HTTP_CLIENT in bin/lein. 2012-08-25 14:46:03 -07:00
Phil Hagelberg
e29418dc58 Bump back to 2.0.0-SNAPSHOT. 2012-08-24 17:26:00 -07:00
Phil Hagelberg
88f00af830 Release 2.0.0-preview9. 2012-08-24 17:02:17 -07:00
Justin Balthrop
23af751b04 Always set -Dclojure.compile.path when we are running from a checkout
This way, you don't have to put this in LEIN_JVM_OPTS
2012-08-17 17:48:42 -07:00
Justin Balthrop
a58bf27819 Try to make the LEIN_JVM_OPTS default sane for :eval-in :classloader
To do this, we grep project.clj. This won't always work, but it is good
enough for a default.
2012-08-17 17:45:39 -07:00
Justin Balthrop
5c56a4c451 Add support for .leinrc
Execute the project's .leinrc whenever bin/lein is run. This can be used
to customize various lein configuration in a specific project.
For example: LEIN_JVM_OPTS and LEIN_HOME.

Also support a global ~/.lein/leinrc for user customizations.
2012-08-17 17:45:39 -07:00
Phil Hagelberg
cc79e72cab Fix project-level conditional for fast trampolines. 2012-08-17 13:43:46 -07:00
Phil Hagelberg
cbdf49168e Allow :eval-in to be a symbol instead of a keyword. 2012-08-17 13:11:00 -07:00
Phil Hagelberg
5e82d1bcb8 Fix file leak when not using fast trampolines. 2012-08-17 10:58:37 -07:00
Phil Hagelberg
27ffe8b101 Make fast trampolines opt-in for now, use shasum for portability. 2012-08-17 10:41:38 -07:00
Phil Hagelberg
f9da16e37a Cache trampoline commands. Fixes #573.
Still needs to resolve the checksum command portably.

Also probably needs to be opt-in, at least at first.
2012-08-17 10:15:43 -07:00
Bruce Adams
56e118087b Download lein.jar to temporary name; rename into place 2012-08-16 17:34:57 -04:00
Phil Hagelberg
fc7e3c7cb9 Back to snapshot. 2012-08-16 13:17:59 -07:00
Phil Hagelberg
ff8ed7f6a8 Release 2.0.0-preview8. 2012-08-16 11:06:45 -07:00
Phil Hagelberg
60702d2ff3 Support larger .lein-classpath in .bat. Fixes #724. 2012-08-09 09:23:03 -07:00
Phil Hagelberg
98dff789e1 Todo updates. 2012-08-08 09:32:01 -07:00
Michael S. Klishin
e165d3f8ab Because startup time is science 2012-08-07 05:13:53 +04:00
Michael S. Klishin
7e12617d6e Consolidate LEIN_JVM_OPTS defaults 2012-08-07 05:12:09 +04:00
Michael S. Klishin
262859b767 Don't set -Xms, it adds to the startup time and has no real benefit 2012-08-07 05:11:18 +04:00
Michael S. Klishin
f97f58ebf9 Add default value for LEIN_JVM_OPTS 2012-08-07 05:08:55 +04:00
Phil Hagelberg
cc9ba8609a Only use leiningen-core/lib for bootstrapping lein's own classpath.
Works around http://dev.clojure.org/jira/browse/CLJ-1034 and is just
generally cleaner.
2012-07-26 14:09:38 -07:00
Phil Hagelberg
296adbf1ab Some more TODOs. 2012-07-17 14:17:50 -07:00
Phil Hagelberg
5120d24732 Explanatory message at the top of bin/lein. 2012-07-03 22:38:06 -07:00
Phil Hagelberg
36856e4fad Drop back to 2.0.0-SNAPSHOT, hopefully for the last time. 2012-06-27 16:54:31 -07:00
Phil Hagelberg
811e974174 Release 2.0.0-preview7. 2012-06-27 16:45:13 -07:00
Phil Hagelberg
25181bed9c Test boot time for lein run rather than lein version.
Who cares if lein version is slow?
2012-06-13 21:43:22 -07:00
Phil Hagelberg
628e13ef8e Fix checkout detection logic in lein.bat; fixes #579.
[ci skip]
2012-06-13 18:59:36 -07:00
Phil Hagelberg
1da790ed78 Bump back to 2.0.0-SNAPSHOT. 2012-06-11 18:45:00 -07:00
Phil Hagelberg
dfb54f3683 Use env in bash shebang. Fixes #624. 2012-06-09 19:48:41 -07:00
Phil Hagelberg
3d57749896 Don't mess with HTTP_CLIENT setting. Fixes #623. 2012-06-09 19:48:40 -07:00
Jorge Barrios
b659769d54 Minor fix to avoid this error:
./lein: line 180: [darwin11: command not found
2012-06-06 15:54:14 -07:00
Phil Hagelberg
14c650c9b0 Release 2.0.0-preview6 2012-06-02 21:07:35 -07:00
Alex Osborne
484151d007 Register certificates before calling get-classpath. Fixes #613
We need to do this as get-classpath can itself trigger the downloading
of dependencies.  This also ensures leiningen-core/resources is added to
the classpath by the wrapper scripts.
2012-06-02 20:10:17 +10:00
Phil Hagelberg
060ab177d2 Add bin/release. 2012-06-01 22:01:48 -07:00
Phil Hagelberg
479fcb83bf http://p.hagelb.org/what.gif
Seriously Maven? You'll accept just any old certificates by default?
2012-06-01 14:08:40 -07:00
Phil Hagelberg
71781a83f3 Back to 2.0.0-SNAPSHOT. 2012-06-01 10:46:54 -07:00
Phil Hagelberg
5a790ca7c8 Release 2.0.0-preview5. 2012-05-31 21:20:42 -07:00
Phil Hagelberg
53c039d3b9 Use cygpath in upgrade target path. Fixes #583.
[ci skip]
2012-05-30 21:19:34 -07:00
Phil Hagelberg
6c927c7e12 Explain how to fall back to insecure SSL when self-install fails.
Fixes #601.

[ci skip]
2012-05-27 22:04:58 -07:00
Michael S. Klishin
6d66921151 Don't break the line 2012-05-17 23:30:20 +04:00
Michael S. Klishin
efc8fb4424 Set default encoding for Lein's JVM to UTF-8, fixes #586
On OS X, JDK 6 uses MacRoman encoding otherwise and it messes
things up for REPL sessions that may have non-ASCII characters
2012-05-17 23:23:12 +04:00
Michiel Borkent
af1aafda6c fixed another quote 2012-05-12 10:59:08 +02:00
Michiel Borkent
e2c874dca4 fixed another quote 2012-05-12 10:38:58 +02:00
Phil Hagelberg
93bb6a1e14 Bump back to 2.0.0-SNAPSHOT. 2012-05-11 18:46:25 -07:00
Phil Hagelberg
104726ee71 Release 2.0.0-preview4. 2012-05-11 18:07:07 -07:00
Phil Hagelberg
95e3863d3f Make in-project .lein-classpath work for specifying plugins. Fixes #508. 2012-05-11 16:24:31 -07:00
Michiel Borkent
139e1014d5 Fixed some quotes. 2012-05-12 01:15:47 +03:00
Leonel Gayard
ef11cb4480 Improvements in lein.bat.
Changed to look for file .lein-classpath only when running from source checkout.
  Fixed construction of variable CLASSPATH to avoid unnecessary quotes and semi colons.
  Removed option Xbootclasspath from command line.
2012-05-11 14:20:13 -03:00
Phil Hagelberg
bf7256ad94 Untabify bin/lein. 2012-05-10 11:45:03 -07:00
Leonel Gayard
9af28dfe83 Changed launcher lein.bat to determine whether it's a source checkout by looking for directory 'src' 2012-05-10 10:30:16 -03:00
Phil Hagelberg
3afbbb8bcd Make sure cygpath affects LEIN_JAR. 2012-05-09 19:17:37 -07:00
Mark Baran
b1022fa4b5 Fixed quoting inside generated trampoline command to pass arguments correctly. 2012-05-07 11:45:41 -07:00
Phil Hagelberg
1cbd58179e Quit checking CLASSPATH in lein.bat.
Disclaimer: http://www.buzzize.com/wp-content/gallery/7i_have_no_idea/thumbs/thumbs_i_have_no_idea_01.jpg
2012-05-07 11:25:18 -07:00
Phil Hagelberg
7c86bdbb83 Set CLASSPATH from scratch rather than checking existing value.
This has only ever caused problems.
2012-05-07 11:24:52 -07:00
Phil Hagelberg
6d404a8422 Explicitly use bash in bin/lein.
We've done this for a while in 1.x; just moving the change to this branch.
2012-05-03 10:52:15 -07:00
Phil Hagelberg
aa1b11969c Drop the --no-check-certificate argument to wget.
This was necessary early on due to a bug where libssl wouldn't
recognize the specific certificate github was using. If you're stuck
on this old version and are having trouble, try exporting
`HTTP_CLIENT=wget --no-check-certificate -O` to get the old behaviour back.
2012-05-03 10:51:32 -07:00
Mark Baran
e474ad270f Fix for trampoline command parsing on Windows. 2012-04-30 15:25:14 -07:00
Andrew Kondratovich
d919f1211f #541 2012-04-30 10:20:27 +03:00
Juergen Hoetzel
e03989d1c2 fix LEIN_HOME path when running under cygwin (required for user profiles) 2012-04-14 12:18:35 -07:00
Juergen Hoetzel
d539c0edbb lein classpath: Accept optional output-file
Aether writes debug information to stdout, resulting in invalid
classpath entries like:

Could not find artifact lein-newnew:lein-newnew:pom:0.2.6 in
central (http://repo1.maven.org/maven2)
2012-04-14 19:12:34 +02:00
Phil Hagelberg
55935d01e9 Remove "bundled mode" from bin/lein. 2012-04-12 11:50:11 -07:00
Phil Hagelberg
030632acf6 Bump back to snapshot. 2012-04-12 10:37:34 -07:00
Phil Hagelberg
a95f990227 Release 2.0.0-preview3. 2012-04-12 10:18:32 -07:00
Phil Hagelberg
6f1638b1a0 Port arbitrary version upgrades from 1.7.1. 2012-04-07 12:40:14 -07:00
Phil Hagelberg
62a8fc107d Remove plugin stuff from 1.x out of lein.bat. 2012-04-01 22:34:15 -07:00
Phil Hagelberg
030e41d72e Remove jline from lein.bat. 2012-04-01 09:17:27 -07:00
Phil Hagelberg
39a6b2c63a Remove Clojure 1.2 from bootclasspath in lein.bat. Might fix #486. 2012-03-31 16:09:42 -07:00
Phil Hagelberg
d7a835efa9 We don't use CLOJURE_JAR anymore.
[ci skip]
2012-03-27 16:13:17 -07:00
Andrew Kondratovich
9afede1820 fixed normal/trampoline statement and arguments 2012-03-23 13:33:59 +03:00
Andrew Kondratovich
f28018a075 fixed lein self-install on windows 2012-03-21 20:32:30 +03:00
Phil Hagelberg
352e8d3f05 Fix target/classes vs classes mismatch in bin/lein.
In conclusion, freaking protocols.
2012-03-19 15:37:40 -07:00
Phil Hagelberg
245b036a4a Back to 2.0.0-SNAPSHOT. 2012-03-11 21:06:48 -07:00
Phil Hagelberg
82bbd3b601 Release 2.0.0-preview2. 2012-03-08 20:33:47 -08:00
Phil Hagelberg
cc711200a4 Move version back to 2.0.0-SNAPSHOT. 2012-03-07 14:24:03 -08:00
Phil Hagelberg
efe16d5dee Release 2.0.0-preview1. 2012-03-07 12:06:48 -08:00
Phil Hagelberg
201afa4830 Do full AOT in Leiningen project itself.
Can't get it to boot in under a second otherwise.
2012-03-07 11:30:26 -08:00
Phil Hagelberg
fe14bed743 Make "lein upgrade" look at preview branch. 2012-03-06 19:49:10 -08:00
Phil Hagelberg
15f0540c04 Use bootstrap classpath for Leiningen. 2012-03-06 19:49:04 -08:00
Phil Hagelberg
532496a1ab Merge branch '1.x'
Conflicts:
	.gitignore
	README.md
	bin/lein
	project.clj
	src/leiningen/compile.clj
	src/leiningen/core.clj
	src/leiningen/help.clj
	src/leiningen/jar.clj
	src/leiningen/repl.clj
	test/leiningen/test/deps.clj
	test/leiningen/test/help.clj
	todo.org
2012-03-04 21:22:20 -08:00
Phil Hagelberg
29c262da3b Don't put $LEIN_DIR/lib on the classpath; that's deprecated. 2012-02-25 22:01:53 -08:00
Tobias Crawley
95aa910052 Bash isn't necessary. 2012-02-16 15:38:19 -05:00
Tobias Crawley
ce65b18049 Allow lein to run when called with no tasks and no .lein-classpath
In that case, $1 isn't set, causing sh to barf on the test.
2012-02-16 15:34:53 -05:00
guns
449c78f490 Replace whoami with id -u test
`id -u` is in the POSIX and LSB specs [1], while `whoami` is not.
Furthermore, the username of UID 0 can be changed (and is sometimes
recommended in a misguided attempt to increase security).

FreeBSD users logged in as `toor` would also slip through the cracks.

[1]: http://pubs.opengroup.org/onlinepubs/009695399/utilities/id.html
     http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/command.html
2012-02-09 18:58:11 -06:00
Phil Hagelberg
80e2b20378 Use absolute paths when checksumming lein's own project.cljs. 2012-02-07 20:26:23 -08:00
Phil Hagelberg
dad9b14cd4 Drop JLine/rlwrap since we have reply. Allow any task to trampoline. 2012-02-07 20:10:51 -08:00
Phil Hagelberg
61f91add22 Fix lein-classpath calculation; the shell hates me for some reason? 2012-02-07 19:00:30 -08:00
Phil Hagelberg
52a51c3570 Recalculate .lein-classpath when project.clj changes. 2012-02-07 18:25:07 -08:00
Phil Hagelberg
30bdafc9d6 Promote leiningen-core/src in classpath when working in checkout. 2012-02-07 17:09:08 -08:00
Phil Hagelberg
622cd625d9 Calculate lein's own classpath in bin/lein.
Bootstrapping like a boss.
2012-01-23 19:17:14 -08:00
Phil Hagelberg
b4661d8cb9 Tidy up from-checkout classpath setup. 2012-01-17 15:11:24 -08:00