aboutsummaryrefslogtreecommitdiff
path: root/lux-lein
diff options
context:
space:
mode:
authorEduardo Julian2016-12-29 16:45:17 -0400
committerEduardo Julian2016-12-29 16:45:17 -0400
commit003d3a63c4c2ec19e42c25b477405774bdcce0d7 (patch)
tree169a06eb4020bf8200a7cb54df40baffe1f58aaa /lux-lein
parent7a9c41f33252e44f36bf667c27739e9afc3085f9 (diff)
- Improved the way commands are taken by lux-lein.
Diffstat (limited to 'lux-lein')
-rw-r--r--lux-lein/src/leiningen/lux.clj27
1 files changed, 7 insertions, 20 deletions
diff --git a/lux-lein/src/leiningen/lux.clj b/lux-lein/src/leiningen/lux.clj
index 40f39f9d3..3c2a8e9f1 100644
--- a/lux-lein/src/leiningen/lux.clj
+++ b/lux-lein/src/leiningen/lux.clj
@@ -13,24 +13,11 @@
;; [Exports]
(defn lux [project & args]
- (case (first args)
- "build"
- (&builder/build project)
-
- "test"
- (&test/test project)
-
- "repl"
- (&repl/repl project)
-
- "auto"
- (case (second args)
- "build"
- (&watch/watch #(&builder/build project) project)
-
- "test"
- (&watch/watch #(&test/test project) project))
-
+ (case args
+ ["build"] (&builder/build project)
+ ["test"] (&test/test project)
+ ["repl"] (&repl/repl project)
+ ["auto" "build"] (&watch/watch #(&builder/build project) project)
+ ["auto" "test"] (&watch/watch #(&test/test project) project)
;; default...
- (println "Commands available: (auto) build, (auto) test, repl"))
- )
+ (println "Commands available: (auto) build, (auto) test, repl")))