diff options
Diffstat (limited to 'gnbug')
-rwxr-xr-x | gnbug | 33 |
1 files changed, 16 insertions, 17 deletions
@@ -70,16 +70,15 @@ even if it exits non-locally. Return the value returned by PROC." ;; avoid them. (sort (map (lambda (file) (let* ((file-details (file-details file)) - (creation-details (creation-details file)) (all-keywords (hashtable-ref file-details 'keywords '()))) (issue file ;; Fallback to filename if title has no alphabetic ;; characters. (let ((title (hashtable-ref file-details 'title ""))) (if (string-any char-set:letter title) title file)) - (assq-ref creation-details 'creator) - (assq-ref creation-details 'created-date) - (assq-ref creation-details 'created-relative-date) + (hashtable-ref file-details 'creator #f) + (hashtable-ref file-details 'created-date #f) + (hashtable-ref file-details 'created-relative-date #f) (hashtable-ref file-details 'assigned '()) ;; "closed" is a special keyword to indicate ;; the open/closed status of an issue. @@ -181,21 +180,21 @@ ports) in that it also supports DOS line endings." (const #t) get-line-dos-or-unix port))) + (call-with-input-pipe + (lambda (port) + (let ((alist (read port))) + (for-each (lambda (key) + (hashtable-set! result key (assq-ref alist key))) + (list 'creator 'created-date 'created-relative-date)))) + "git" "log" "--diff-filter=A" + (string-append "--format=format:(" + "(creator . \"%an\")" + "(created-date . %at)" + "(created-relative-date . \"%ar\")" + ")") + "--" file) result)) -(define (creation-details file) - "Return an association list of creation details about FILE extracted -from the git repository." - (call-with-input-pipe - read - "git" "log" "--diff-filter=A" - (string-append "--format=format:(" - "(creator . \"%an\")" - "(created-date . %at)" - "(created-relative-date . \"%ar\")" - ")") - "--" file)) - (define (git-updated-files transducer start-commit end-commit) "Use TRANSDUCER to transduce over the list of files updated between START-COMMIT and END-COMMIT." |