This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(import '(java.util Base64)) | |
(defn b64encode-to-bytes [to-encode] | |
(.encode (Base64/getEncoder) (.getBytes to-encode))) | |
(defn b64encode [to-encode] | |
(.encodeToString (Base64/getEncoder) (.getBytes to-encode))) | |
(defn b64decode [to-decode] | |
(String. (.decode (Base64/getDecoder) (.getBytes to-decode)))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun rot-time-duration (begin &optional end) | |
(if end | |
(org-minutes-to-clocksum-string | |
(- (org-duration-to-minutes end) | |
(org-duration-to-minutes begin))) | |
(seq-let (begin end) (mapcar 's-trim (s-split "-" begin)) | |
(rot-time-duration begin end)))) | |
;; (rot-time-duration "9:00" "17:00") |
OlderNewer