Skip to content
Snippets Groups Projects
Commit fc1532b7 authored by Allen Gilliland's avatar Allen Gilliland
Browse files

custom leiningen tasks for running npm and gulp so that we can now run all our...

custom leiningen tasks for running npm and gulp so that we can now run all our build steps via leiningen.
parent 7d95659d
No related merge requests found
......@@ -7,7 +7,8 @@ pom.xml
pom.xml.asc
*.jar
*.class
/.lein-*
/.lein-env
/.lein-repl-history
/.nrepl-port
.hgignore
.hg/
......
lein_tasks
(ns leiningen.gulp
(:use clojure.java.shell))
(defn gulp [projects & args]
;; TODO - some better validations such as checking that we have gulp available
(println "Running `gulp build` to assemble frontend assets into a better format")
(let [result (sh (str (:root projects) "/node_modules/gulp/bin/gulp.js") "build")]
(if (= 0 (:exit result))
(println (:out result))
(println (:err result)))))
\ No newline at end of file
(ns leiningen.npm
(:use clojure.java.shell))
(defn npm [projects & args]
;; TODO - some better validations such as checking if `npm` is available
(println "Running `npm install` to download javascript dependencies")
(let [result (sh "npm" "install")]
(if (= 0 (:exit result))
(println (:out result))
(println (:err result)))))
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment