diff options
Diffstat (limited to 'web/view/markdown.scm')
-rw-r--r-- | web/view/markdown.scm | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/web/view/markdown.scm b/web/view/markdown.scm index 900378e..8632b8b 100644 --- a/web/view/markdown.scm +++ b/web/view/markdown.scm @@ -91,7 +91,15 @@ commit-sha)) -(define (commit-file repo file-path content commit-message username email) + + + +(define* (commit-file repo file-path content commit-message username email #:optional (prev-commit "")) + (if (string=? prev-commit (get-latest-commit-sha1 repo)) + #t + (throw 'system-error (format #f "Commits do no match.Please pull in latest changes for current * ~a * and prev * ~a * " + (get-latest-commit-sha1 repo) prev-commit)) + ) (if (is-repo? repo) (match (file-exists? (string-append repo "/" file-path)) (#t |