File tree 2 files changed +14
-8
lines changed
2 files changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -24,3 +24,4 @@ pom.xml.asc
24
24
** /* /* .ipynb_checkpoints
25
25
concepts /functions-generating-functions /introduction_files /
26
26
concepts /functions-generating-functions /* .html
27
+ exercises /** /* .bak
Original file line number Diff line number Diff line change 35
35
example (if practice?
36
36
(str dir " .meta/example.clj" )
37
37
(str dir " .meta/exemplar.clj" ))
38
- src (str dir " src/" (->snake_case slug) " .clj" )]
39
- (shell/sh " cp" example src)
40
- (= " pass" ((json/parse-string
41
- (:out (shell/sh (str test-runner-dir " test-runner.clj" )
42
- slug
43
- dir
44
- dir)))
45
- " status" ))))
38
+ src (str dir " src/" (->snake_case slug) " .clj" )
39
+ src-copy (str src " .bak" )]
40
+ (shell/sh " cp" src src-copy)
41
+ (try
42
+ ((shell/sh " cp" example src)
43
+ (= " pass" ((json/parse-string
44
+ (:out (shell/sh (str test-runner-dir " test-runner.clj" )
45
+ slug
46
+ dir
47
+ dir)))
48
+ " status" )))
49
+ (finally (shell/sh " mv" src-copy src)))))
50
+
46
51
47
52
(defn test-exercises! []
48
53
(let [exercises (or (seq (take 1 *command-line-args*))
You can’t perform that action at this time.
0 commit comments