ambrevar/storage: Add absolute-path.
parent
3fa99afa57
commit
7db651b2b7
|
@ -20,6 +20,12 @@
|
||||||
(first (json:decode-json-from-string
|
(first (json:decode-json-from-string
|
||||||
(cmd:$cmd "findmnt -n --fstab --output TARGET --json")))))))
|
(cmd:$cmd "findmnt -n --fstab --output TARGET --json")))))))
|
||||||
|
|
||||||
|
(defun absolute-path (path-designator)
|
||||||
|
(uiop:native-namestring
|
||||||
|
(uiop:truename* (if (pathnamep path-designator)
|
||||||
|
path-designator
|
||||||
|
(uiop:parse-native-namestring path-designator)))))
|
||||||
|
|
||||||
(defun subpath (root &rest subdirs)
|
(defun subpath (root &rest subdirs)
|
||||||
"Return merged paths as a string.
|
"Return merged paths as a string.
|
||||||
SUBDIRS can be either a single path or a list of paths."
|
SUBDIRS can be either a single path or a list of paths."
|
||||||
|
@ -207,6 +213,7 @@ If DESTINATION ends with '.gpg', it gets GPG-encrypted."
|
||||||
("Staged files"
|
("Staged files"
|
||||||
,(sera:lines (legit:git-value repository '(staged) (legit:git-diff :name-only t :cached t)))))))
|
,(sera:lines (legit:git-value repository '(staged) (legit:git-diff :name-only t :cached t)))))))
|
||||||
|
|
||||||
|
;; TODO: Add option to push upstream?
|
||||||
(export-always 'project-statuses)
|
(export-always 'project-statuses)
|
||||||
(defun project-statuses ()
|
(defun project-statuses ()
|
||||||
(delete-if (sera:op (and (null (second (second _1)))
|
(delete-if (sera:op (and (null (second (second _1)))
|
||||||
|
|
Loading…
Reference in New Issue