Skip to content

Commit

Permalink
change include to regex set
Browse files Browse the repository at this point in the history
  • Loading branch information
burn2delete committed Dec 23, 2017
1 parent d6153c1 commit 127a847
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/degree9/boot_exec.clj
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@
tmp (get-directory *opts*)
cmd (sh process args (.getAbsolutePath tmp))
output (:output *opts*)
include (:include *opts* #{#".*"})
exclude (:exclude *opts*)
fail (:fail *opts*)]
(util/info (string/join ["Executing Process: " process "\n"]))
Expand All @@ -97,7 +98,7 @@
output (util/info "%s" stdout)
:else (util/dbug "%s" stdout)))
(util/info "Process completed successfully.\n"))
(if (:include *opts*) (-> fileset (boot/add-resource tmp :exclude exclude) boot/commit!) fileset)))
(-> fileset (boot/add-resource tmp :include include :exclude exclude) boot/commit!)))

(boot/deftask exec
"Process execution via Apache Commons Exec"
Expand All @@ -107,7 +108,7 @@
d directory VAL str "Optional target directory to execute the process within."
g global VAL str "Optional global path to search for the executable."
l local VAL str "Optional local path to search for the executable."
i include bool "Include files added to the working directory."
i include VAL #{regex} "Include files added to the working directory."
e exclude VAL #{regex} "Filter included files from the working directory."
o output bool "Show executable output. By default output only with verbose (boot -vv)."
f fail bool "Task failure when process returns non-zero error code."]
Expand Down
1 change: 1 addition & 0 deletions src/degree9/boot_exec/impl.clj
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
(ns degree9.boot-exec.impl)

0 comments on commit 127a847

Please sign in to comment.