@@ -20,3 +20,9 @@
(with-input-from-string (input value)
(%secret/pass (format nil "insert --force --multiline ~{~A~^/~}" path)
:input input :output :string)))
+
+(defmacro secret/with ((var path) &body body)
+ `(let ((,var (ignore-errors (secret/get ,path))))
+ (unwind-protect
+ (progn ,@body)
+ (fill ,var #\Space))))