diff --git a/src/main.lisp b/src/main.lisp index 5fcb2b9..e9b75ca 100644 --- a/src/main.lisp +++ b/src/main.lisp @@ -324,7 +324,26 @@ before after)) (t ;; process the files - (mapcar #'process-command-file arguments)))) + ;; other options are not going to be used here + (let ((cli-options `(("--type" ,type) + ("--encoding" ,encoding) + ("--set" ,set) + ("--with" ,with) + ("--field" ,field) + ("--cast" ,cast) + ("--before" ,before) + ("--after" ,after)))) + (loop :for (cli-option-name cli-option-value) + :in cli-options + :when cli-option-value + :do (log-message + :fatal + "Option ~s is ignored when using a load file" + cli-option-name)) + + ;; when we issued a single error previously, do nothing + (unless (remove-if #'null (mapcar #'second cli-options)) + (mapcar #'process-command-file arguments)))))) (source-definition-error (c) (log-message :fatal "~a" c) diff --git a/src/utils/report.lisp b/src/utils/report.lisp index 0997ee2..9458a66 100644 --- a/src/utils/report.lisp +++ b/src/utils/report.lisp @@ -133,8 +133,9 @@ (when (and ws (not (= ws 0.0))) (format-interval ws nil))))) (defun report-pgstate-stats (pgstate legend) - (with-slots (read rows errs secs rs ws) pgstate - (report-footer legend read rows errs secs rs ws))) + (with-slots (tabnames read rows errs secs rs ws) pgstate + (when tabnames + (report-footer legend read rows errs secs rs ws)))) ;;; ;;; Pretty print the whole summary from a state