Move git-last-update to git.scm
This commit is contained in:
parent
10e7025d6f
commit
d71be13c37
1 changed files with 3 additions and 15 deletions
|
@ -1,11 +1,11 @@
|
|||
(define-module (tekuti projects)
|
||||
#:use-module ((tekuti config) #:select (*projects-dir*))
|
||||
#:use-module (ice-9 ftw)
|
||||
#:use-module (ice-9 match)
|
||||
#:use-module (tekuti page-helpers)
|
||||
#:use-module ((tekuti config) #:select (*projects-dir*))
|
||||
#:use-module (ice-9 popen)
|
||||
#:use-module (ice-9 rdelim)
|
||||
#:use-module (tekuti git)
|
||||
#:use-module (ice-9 popen)
|
||||
#:use-module (tekuti page-helpers)
|
||||
#:export (page-projects))
|
||||
|
||||
(use-modules (ice-9 ftw)
|
||||
|
@ -34,18 +34,6 @@
|
|||
(read-line)))
|
||||
"Unknown")))
|
||||
|
||||
(define (git-last-update project)
|
||||
"Check when the last update upstream was."
|
||||
(let* ((pipe (open-input-pipe
|
||||
(string-append
|
||||
"git --git-dir=" project
|
||||
" log -1 --format=%ar 2>/dev/null")))
|
||||
(relative-last-update (read-line pipe)))
|
||||
(close-pipe pipe)
|
||||
(if (eof-object? relative-last-update)
|
||||
"never"
|
||||
relative-last-update)))
|
||||
|
||||
(define (gitless name)
|
||||
(let ((pos (string-contains name ".git")))
|
||||
(if pos
|
||||
|
|
Loading…
Reference in a new issue