File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1212(import ./commands/stats )
1313
1414(import ./date :as d )
15+ (import ./errors )
1516(import ./schedule_parser )
1617
1718# backup command needs to be first
2728 schedule_tasks/build-command
2829 stats/build-command ])
2930
30- (defn- print-errors [errors ]
31- (loop [error :in errors ]
32- (print error )))
33-
3431# # —————————————————————————————————————————————————————————————————————————————————————————————————
3532# # Public Interface
3633
5148 (def errors (filter identity (flatten (map (fn [c ] (c :errors )) commands ))))
5249 (if (any? errors )
5350 (do
54- (print-errors errors )
51+ (errors/ print-errors-without-status-code errors )
5552 plan )
5653 (reduce (fn [new-plan command-and-arguments ]
5754 (def command (first (command-and-arguments :command )))
Original file line number Diff line number Diff line change 1313(defn format-command-errors [command errors ]
1414 (map (fn [error ] (string command " " (string/ascii-lower error ) " ." )) errors ))
1515
16+ # TODO: This function should go away.
17+ (defn print-errors-without-status-code [errors ]
18+ (loop [error :in errors ]
19+ (print error )))
20+
1621(defn print-errors [errors exit-status-code ]
1722 (each error errors (print (string error " ." )))
1823 (os/exit exit-status-code ))
You can’t perform that action at this time.
0 commit comments