Skip to content

Commit c12b2a9

Browse files
committed
add :src-files to event map
1 parent 355980c commit c12b2a9

File tree

5 files changed

+35
-10
lines changed

5 files changed

+35
-10
lines changed

CHANGES.md

+8-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,17 @@
11
# boot
22

3+
## 0.2.1
4+
5+
*Wed Nov 6 11:53:13 EST 2013*
6+
7+
* prepopulate :src-files event key with source files (gitignored files not
8+
removed)
9+
310
## 0.2.0
411

512
*Fri Nov 1 02:12:23 EDT 2013*
613

7-
* prepopulate :watch event key with source files
14+
* prepopulate :watch event key with source files (gitignored files removed)
815
* add recursive task :main key—keywords refer to other tasks
916

1017
## 0.1.1

README.md

+16-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,21 @@ or evaluates an expression as specified in the configuration.
88

99
*This is experimental software and subject to frequent change.*
1010

11-
**Current version: 0.2.0**
11+
### Dependency
12+
13+
Artifacts are published on [Clojars][6].
14+
15+
```clojure
16+
[tailrecursion/hoplon "0.2.1"]
17+
```
18+
19+
```xml
20+
<dependency>
21+
<groupId>tailrecursion</groupId>
22+
<artifactId>hoplon</artifactId>
23+
<version>0.2.1</version>
24+
</dependency>
25+
```
1226

1327
## Overview
1428

@@ -131,3 +145,4 @@ Distributed under the Eclipse Public License, the same as Clojure.
131145
[3]: https://github.com/technomancy/leiningen/blob/master/doc/PROFILES.md
132146
[4]: https://github.com/technomancy/leiningen
133147
[5]: https://github.com/tailrecursion/boot/blob/master/boot.edn
148+
[6]: https://clojars.org/tailrecursion/boot

project.clj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
(defproject tailrecursion/boot "0.2.0"
1+
(defproject tailrecursion/boot "0.2.1"
22
:description "A dependency setup/build tool for Clojure."
33
:url "https://github.com/tailrecursion/boot"
44
:license {:name "Eclipse Public License"

script/push

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ v=$(cat project.clj |head -1 |awk '{print $3}' |sed 's/"//g')
1010
if [ "$VERSION" == "$v" ]; then
1111
git tag -a -m "$MESSAGE" "$VERSION"
1212
git push --tags
13+
lein push
1314
else
1415
echo "$0: version doesn't match project.clj" 1>&2
1516
exit 1

src/tailrecursion/boot/core.clj

+9-7
Original file line numberDiff line numberDiff line change
@@ -108,14 +108,16 @@
108108
`(defn ~(with-meta name {::task true}) ~@args))
109109

110110
(defn make-event
111-
([boot]
112-
(let [srcs (->> @boot :src-paths (map io/file) (mapcat file-seq)
113-
(filter #(.isFile %)) (remove (partial ignored? boot)) set)]
114-
{:id (gensym)
115-
:time (System/currentTimeMillis)
116-
:watch {:time srcs, :hash srcs}}))
111+
([boot]
112+
(make-event boot {}))
117113
([boot event]
118-
(merge event {:id (gensym) :time (System/currentTimeMillis)})))
114+
(let [srcs (->> @boot :src-paths (map io/file)
115+
(mapcat file-seq) (filter #(.isFile %)))
116+
watched (->> srcs (remove (partial ignored? boot)) set)]
117+
(merge event {:id (gensym)
118+
:time (System/currentTimeMillis)
119+
:watch {:time watched, :hash watched}
120+
:src-files (set srcs)}))))
119121

120122
(defn init! [env]
121123
(doto (atom env) (add-watch ::_ #(configure! %3 %4))))

0 commit comments

Comments
 (0)