(cond
((null rev2) (apply #'vc-pijul--async "diff" buffer files))
((apply #'vc-pijul--async "change" buffer (list rev2))))
1)))
(defun vc-pijul-previous-revision (file rev)
"Return the previous revision of REV for FILE.
If there is no previous revision return nil."
(with-temp-buffer
(cond
((apply
#'vc-pijul--out-ok
(append (list "log" "--hash-only" "--")
(cond (file (list file)))))
(goto-char (point-min))
(cond
((search-forward rev nil t)
(forward-line 1)
(cond
((< (point) (point-max))
(buffer-substring (point) (point-at-eol))))))))))
(defun vc-pijul-next-revision (file rev)
"Return the next revision of REV for FILE.
If there is no next revision return nil."
(with-temp-buffer
(cond
((vc-pijul--out-ok
"log" "--hash-only" "--" file)
(goto-char (point-min))
(cond
((search-forward rev nil t)
(forward-line 0)
(cond
((> (point) (point-min))
(forward-line -1)
(buffer-substring (point) (point-at-eol))))))))))