Skip to content

Commit

Permalink
prepare 0.4.3 release
Browse files Browse the repository at this point in the history
- fix problem when there is no whitespace before the ns prefix in the
  ns body
- adds build.sh for convenience
  • Loading branch information
benedekfazekas committed Apr 12, 2015
1 parent bd75bf5 commit a1df6e9
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ It is an inlining tool which inlines your project's dependencies at packaging ti

## Usage

Put `[thomasa/mranderson "0.4.2"]` into the `:plugins` vector of your project.clj.
Put `[thomasa/mranderson "0.4.3"]` into the `:plugins` vector of your project.clj.

Additionally you also need to mark some of the dependencies in your dependencies vector in the project's `project.clj` with `^:source-dep` meta tag. For example:

Expand Down
14 changes: 14 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

# runs source-deps and tests and then provided lein target with mranderson

function check_result {
if [ $? -ne 0 ]; then
echo "FAILED"
exit 1
fi
}

lein do clean, source-deps :skip-javaclass-repackage true
check_result
lein with-profile plugin.mranderson/config "$@"
2 changes: 1 addition & 1 deletion project.clj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(defproject thomasa/mranderson "0.4.2"
(defproject thomasa/mranderson "0.4.3"
:description "Leiningen plugin to download and use some dependencies as source."
:url "https://github.com/benedekfazekas/mranderson"
:license {:name "Eclipse Public License"
Expand Down
2 changes: 1 addition & 1 deletion src/leiningen/source_deps.clj
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
(defn- update-file [file prefixes prefix]
(let [old (slurp file)
new (-> (str/replace old (re-pattern (str "(\\[\\s*)" prefix "(\\s+\\[?)")) (str "$1" (prefixes prefix) "$2"))
(str/replace (re-pattern (str "(\\s+)" prefix "([\\s\\.])")) (str "$1" (prefixes prefix) "$2")))]
(str/replace (re-pattern (str "(\\s+\\(?)" prefix "([\\s\\.])")) (str "$1" (prefixes prefix) "$2")))]
(when-not (= old new)
(spit file new))))

Expand Down

0 comments on commit a1df6e9

Please sign in to comment.