Commit fda288b6 authored by Francois-Rene Rideau's avatar Francois-Rene Rideau

Update some calls to git wrt the first return value being success indicator boolean.

parent fc5676c1
......@@ -53,5 +53,5 @@
(defun git-all-committed-p ()
"is your checkout clean, with all files committed?"
(null (git '(status -s) :output :lines)))
(null (nth-value 1 (git '(status -s) :output :lines))))
......@@ -5,17 +5,18 @@
(defparameter *version-tag-glob* "[0-9][.][0-9]*")
(defun version-from-tag (&optional commit)
(git `(describe --tags --match ,*version-tag-glob* ,commit)
:output :line :directory (pn)))
;; run-program issue: :output :line closes the fd, which causes the program to die in error.
(first (nth-value 1 (git `(describe --tags --match ,*version-tag-glob* ,commit) :output :lines))))
(defun version-from-file (&optional commit)
(if commit
(git `(show (,commit":version.lisp-expr")) :output :form)
(nth-value 1 (git `(show (,commit":version.lisp-expr")) :output :form))
(safe-read-file-form (pn "version.lisp-expr"))))
(defun debian-version-from-file (&optional commit)
(match (if commit
(git `(show (,commit":debian/changelog")) :output :line)
;; run-program issue: :output :line closes the fd, which causes the program to die in error.
(first (nth-value 1 (git `(show (,commit":debian/changelog")) :output :lines)))
(read-file-line (pn "debian/changelog")))
((ppcre "^[^(]*\\(([-0-9.:-]+)\\)" ver) ver)))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment