Compare commits

..

26 Commits

Author SHA1 Message Date
Nathan Dwarshuis 666031d407 ENH update packages 2024-11-24 11:52:26 -05:00
Nathan Dwarshuis ae8041b7ff FIX clock thingy 2024-11-21 09:13:50 -05:00
Nathan Dwarshuis 14d4c2d696 ENH update packages 2024-11-17 10:33:09 -05:00
Nathan Dwarshuis ec18914035 ENH update packages 2024-11-10 12:35:26 -05:00
Nathan Dwarshuis 889578ce60 ENH update packages 2024-11-03 15:52:04 -05:00
Nathan Dwarshuis e2f88b3462 ENH update packages 2024-10-27 07:52:13 -04:00
Nathan Dwarshuis b96539afc8 FIX extraneous print thing 2024-10-20 20:54:09 -04:00
Nathan Dwarshuis b4d51331c9 ENH update packages 2024-10-20 10:34:15 -04:00
Nathan Dwarshuis d96718118a ENH update packages 2024-10-13 09:53:41 -04:00
Nathan Dwarshuis 976c81304d FIX company being silly and slow 2024-10-07 13:50:46 -04:00
Nathan Dwarshuis ea05678f3c ENH update packages 2024-10-06 09:19:17 -04:00
Nathan Dwarshuis 211e2dc3f3 FIX drawer nil error 2024-10-06 09:11:22 -04:00
Nathan Dwarshuis 5e3987f01f ENH update packages 2024-09-29 09:57:08 -04:00
Nathan Dwarshuis c7d9b1bca5 FIX timestamp bug 2024-09-22 18:28:31 -04:00
Nathan Dwarshuis e9ddf983f6 ENH update packages 2024-09-21 08:12:21 -04:00
Nathan Dwarshuis 9194b18ff1 ENH update packages 2024-09-15 07:04:53 -04:00
Nathan Dwarshuis 177ad2de34 ENH update packages 2024-09-08 09:36:34 -04:00
Nathan Dwarshuis 736a518571 ENH update packages 2024-09-01 11:56:41 -04:00
Nathan Dwarshuis 6d7f92dbbe FIX more stuff 2024-08-25 21:47:16 -04:00
Nathan Dwarshuis 06be547a0b FIX other node property things that should have broken 2024-08-25 17:26:18 -04:00
Nathan Dwarshuis 96bd00f938 FIX node prop error 2024-08-25 17:21:44 -04:00
Nathan Dwarshuis 3fb0f43f94 ENH update packages 2024-08-25 13:10:52 -04:00
Nathan Dwarshuis 59f9c58718 WIP test org-ml 6.0.0 2024-08-24 19:09:37 -04:00
Nathan Dwarshuis c1db214e70 Merge branch 'master' into dev_org_ml 2024-06-13 17:53:55 -04:00
Nathan Dwarshuis 62b12ac877 ENH use updated repo 2024-06-13 17:52:25 -04:00
Nathan Dwarshuis 6febee2875 ENH use org dev branch (kinda) 2023-06-19 17:56:01 -04:00
8 changed files with 167 additions and 143 deletions

View File

@ -833,6 +833,8 @@ Company provides a dropdown of completion options. It has many backends which ar
:delight "κ"
:config
(setq company-idle-delay 0
company-dabbrev-minimum-length 5
company-dabbrev-other-buffers nil
company-minimum-prefix-length 3))
#+END_SRC
** auto formatting
@ -1784,11 +1786,11 @@ Save all org buffers 1 minute before the hour, then commit whatever I saved.
*** stateless configuration
=org-ml= provides stateless functions for operating on org buffers.
#+BEGIN_SRC emacs-lisp
(use-package org-ml
:straight t
:config
;; make the match functions super fast with memoization
(setq org-ml-memoize-match-patterns t))
;; (use-package org-ml
;; :straight t
;; :config
;; ;; make the match functions super fast with memoization
;; (setq org-ml-memoize-match-patterns t))
#+END_SRC
*** personal library
@ -1804,9 +1806,11 @@ The advantage of doing it this way is that I can byte-compile and test independe
(nd/load-and-compile (nd/expand-lib-directory "interval"))
(nd/load-and-compile (nd/expand-lib-directory "dag"))
(nd/load-and-compile (nd/expand-lib-directory "org-x"))
(nd/load-and-compile (nd/expand-local-pkg-directory "org-ml"))
(require 'dag)
(require 'org-x)
(require 'org-ml)
#+end_src
** buffer interface
*** folding
@ -1997,24 +2001,24 @@ Some common functions that I use often that don't seem to exist
** calfw
This is a nifty calendar. Sometimes it is way faster than the agenda buffer for looking at long term things.
#+BEGIN_SRC emacs-lisp
;; (use-package calfw
;; :straight t
;; :config
;; (setq cfw:fchar-junction ?╋
;; cfw:fchar-vertical-line ?┃
;; cfw:fchar-horizontal-line ?━
;; cfw:fchar-left-junction ?┣
;; cfw:fchar-right-junction ?┫
;; cfw:fchar-top-junction ?┯
;; cfw:fchar-top-left-corner ?┏
;; cfw:fchar-top-right-corner ?┓))
(use-package calfw
:straight t
:config
(setq cfw:fchar-junction ?╋
cfw:fchar-vertical-line ?┃
cfw:fchar-horizontal-line ?━
cfw:fchar-left-junction ?┣
cfw:fchar-right-junction ?┫
cfw:fchar-top-junction ?┯
cfw:fchar-top-left-corner ?┏
cfw:fchar-top-right-corner ?┓))
;; (use-package calfw-org
;; :straight t
;; :after calfw
;; :config
;; (setq cfw:org-agenda-schedule-args
;; '(:deadline* :scheduled* :timestamp)))
(use-package calfw-org
:straight t
:after calfw
:config
(setq cfw:org-agenda-schedule-args
'(:deadline* :scheduled* :timestamp)))
#+END_SRC
** exporting
*** latex to pdf command
@ -3659,6 +3663,12 @@ Everyone forgets keybindings. When typing a key chord, this will display a windo
:init
(which-key-mode))
#+END_SRC
** company
#+begin_src emacs-lisp
(define-key company-active-map (kbd "<tab>") 'company-complete-selection)
(define-key company-active-map (kbd "<return>") 'company-complete-selection t)
(define-key company-active-map "\r" 'company-complete-selection t)
#+end_src
** hydra
Hydra allows commands to be arranged on a set of keybindings like a tree.
#+begin_src emacs-lisp

View File

@ -10,7 +10,13 @@
;; ensure we use built-in org mode
;; (use-package org :straight org-plus-contrib)
(straight-use-package '(org :type built-in))
;; (straight-use-package '(org :type built-in))
(straight-use-package
'(org :type git
:repo "git://git.savannah.gnu.org/emacs/org-mode.git"
:branch "release_9.7.9"))
;;(load-file "~/.config/emacs/straight/repos/org/lisp/org-element-ast.el")
;;(load-file "~/.config/emacs/straight/repos/org/lisp/org-element.el")
;; load everything else
(org-babel-load-file nd/conf-main)

View File

@ -77,7 +77,7 @@ Returns a new timespan."
(when timestamp
(let ((offset (org-element-property :begin headline))
(start-time (org-ml-timestamp-get-start-time timestamp))
(range (org-ml-timestamp-get-range timestamp)))
(range (org-ml-timestamp-get-length timestamp)))
(org-x-agg--make-timespan start-time range offset filepath))))
(defun org-x-agg--effort-to-seconds (effort-str)
@ -178,7 +178,7 @@ time of the :start-time property."
(cl-flet
((append-unixtime
(span)
`(:unixtime ,(org-ml-time-to-unixtime (plist-get span :start-time)) ,@span)))
`(:unixtime ,(org-ml-timelist-to-unixtime (plist-get span :start-time)) ,@span)))
(-map #'append-unixtime timespans)))
;; get conflict headlines
@ -230,7 +230,7 @@ returned."
"Return TIMESPANS that conflict with each other.
The returned list will be a list of pairs of timespans
like (SPAN-a SPAN-b) which are two timespans that conflict."
(->> (--filter (org-ml-time-is-long (plist-get it :start-time)) timespans)
(->> (--filter (org-ml-timelist-has-time (plist-get it :start-time)) timespans)
(org-x-agg--timespans-append-unixtime)
(org-x-agg--timespans-remove-past)
(--sort (< (plist-get it :unixtime) (plist-get other :unixtime)))
@ -265,7 +265,7 @@ like (SPAN-a SPAN-b) which are two timespans that conflict."
;; `encode-time' and `decode-time' might not use the right time zone
;; unless specified manually
(-let* ((tz (current-time-zone))
(start-time* (if (org-ml-time-is-long start-time) start-time
(start-time* (if (org-ml-timelist-has-time start-time) start-time
`(,@(-take 3 start-time) 0 0)))
((y m d H M) start-time*)
(start-epoch (encode-float-time `(0 ,M ,H ,d ,m ,y nil nil ,tz)))

View File

@ -44,7 +44,7 @@
"Headline todo keyword for canceled task or project.")
(defconst org-x-done-keywords `(,org-x-kw-done ,org-x-kw-canc)
"Headline todo keywords that mark a task as 'complete'.")
"Headline todo keywords that mark a task as `complete'.")
(defconst org-x-meeting-keywords (cons org-x-kw-todo org-x-done-keywords)
"Allowed keywords for meetings.")

View File

@ -66,7 +66,7 @@
(defun org-x-dag-timestamp-to-epoch (ts)
(->> (org-ml-timestamp-get-start-time ts)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
;; calendar interface
@ -91,7 +91,7 @@
(defun org-x-dag-datetimes-same-length-p (datetime0 datetime1)
;; ASSUME all digits in this comparison are on the calendar/clock (eg day 32
;; does not 'rollover' to day 1 on the next month)
(not (xor (org-ml-time-is-long datetime0) (org-ml-time-is-long datetime1))))
(not (xor (org-ml-timelist-has-time datetime0) (org-ml-timelist-has-time datetime1))))
;; TODO some of this is redundant because I'm checking the length twice
;; Maybe a -> Maybe a -> (a -> a -> b) -> b -> Maybe b
@ -110,7 +110,7 @@
(defun org-x-dag-datetime-split (datetime)
;; TODO this function doesn't guarantee that a short timestamp is properly
;; formatted
(if (org-ml-time-is-long datetime)
(if (org-ml-timelist-has-time datetime)
(-split-at 3 datetime)
`(,(org-x-dag-datetime-to-date datetime) nil)))
@ -403,7 +403,7 @@ relative shift in days from ABS."
(defun org-x-dag-partition-timestamp (ts)
(list :datetime (org-ml-timestamp-get-start-time ts)
:length (org-ml-timestamp-get-range ts)
:length (org-ml-timestamp-get-length ts)
:pos (org-ml-get-property :begin ts)
:repeater (org-ml-timestamp-extract-modulus 'repeater ts)
:warning (org-ml-timestamp-extract-modulus 'warning ts)))
@ -427,7 +427,7 @@ relative shift in days from ABS."
(-max-by #'org-x-dag-pts> ps))
(defun org-x-dag-pts-is-long-p (pts)
(org-ml-time-is-long (plist-get pts :datetime)))
(org-ml-timelist-has-time (plist-get pts :datetime)))
(defun org-x-dag-pts-to-epoch (pts)
(->> (plist-get pts :datetime)
@ -804,7 +804,7 @@ used for optimization."
(-if-let (,c (-some->> it-planning
(org-ml-get-property :closed)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
(cond
((equal it-todo org-x-kw-canc)
(let ((it-comptime (complete-time ,c t)))
@ -852,7 +852,7 @@ deadline (eg via epoch time) or if it has a repeater."
(if (car (org-ml-timestamp-get-repeater deadline)) t
(let ((this-epoch (-some->> deadline
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime))))
(org-ml-timelist-to-unixtime))))
(< parent-epoch this-epoch))))))
(defun org-x-dag-bs-action-project-inner (node-data ancestry child-bss)
@ -1298,7 +1298,7 @@ deadline (eg via epoch time) or if it has a repeater."
(deadline (-some->> planning
(org-ml-get-property :deadline)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime))))
(org-ml-timelist-to-unixtime))))
(list :canceled-parent-p (or c (equal todo org-x-kw-canc))
:held-parent-p (or h (equal todo org-x-kw-hold))
:parent-deadline (cond
@ -1526,7 +1526,7 @@ deadline (eg via epoch time) or if it has a repeater."
(-if-let (sched (-some->> (plist-get m :planning)
(org-ml-get-property :scheduled)
(org-ml-timestamp-get-start-time)))
(if (org-ml-time-is-long sched)
(if (org-ml-timelist-has-time sched)
(either :left "WKP branch node must be short scheduled")
(-let (((&plist :date d :offset o) date-offset)
(this-abs (org-x-dag-date-to-absolute sched)))
@ -1557,7 +1557,7 @@ deadline (eg via epoch time) or if it has a repeater."
(offset (->> (alist-get org-x-prop-week-len props nil nil #'equal)
(string-to-number)))
(ancestry (cond
((or (not datetime) (org-ml-time-is-long datetime))
((or (not datetime) (org-ml-timelist-has-time datetime))
(either :left "WKP root nodes must be short scheduled"))
((< offset 1)
(either :left "WKP root week length must be an int >= 1"))
@ -1811,7 +1811,7 @@ denoted by CUR-KEY with any errors that are found."
(lambda (id this-h res)
(-let* (((&alist :lifetime l) res)
(d (org-x-dag-adjlist-id-planning adjlist :deadline id))
(ns (if (car (org-ml-timestamp-get-repeater d))
(ns (if (and d (car (org-ml-timestamp-get-repeater d)))
(org-x-dag--ns-err "EPG has deadline with repeater" nil)
(either :right `(:committed ,l :deadline ,d)))))
(ht-set this-h id ns)
@ -2044,8 +2044,8 @@ DEF-FUN and the output from GET-FUN (type :: a -> NS)."
(org-ml-timestamp-get-start-time)))
(let ((set-dead (org-ml-timestamp-get-start-time to-set)))
(cond
((xor (org-ml-time-is-long this-dead)
(org-ml-time-is-long set-dead))
((xor (org-ml-timelist-has-time this-dead)
(org-ml-timelist-has-time set-dead))
(-> "EPG as parent with different deadline precision"
(org-x-dag--ns-err nil)))
((org-x-dag-datetime< set-dead this-dead)
@ -2599,7 +2599,7 @@ highest in the tree."
(defun org-x-dag-id->planning-epoch (which id)
(-some->> (org-x-dag-id->planning-datetime which id)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
(defun org-x-dag-id->agenda-timestamp (id)
"Retrieve timestamp information of ID for sorting agenda views.
@ -2892,7 +2892,7 @@ encountered will be returned."
('warning '(:warning-value :warning-unit :warning-type))
('repeater '(:repeater-value :repeater-unit :repeater-type))))
(islongp (->> (org-ml-timestamp-get-start-time ts)
(org-ml-time-is-long))))
(org-ml-timelist-has-time))))
(-when-let ((value unit type) (org-ml-get-properties props ts))
(let ((v (convert-value islongp value unit))
(u (convert-unit unit)))
@ -2944,7 +2944,7 @@ FUTURE-LIMIT in a list."
(defun org-x-dag-get-scheduled-at (sel-date pts)
(-let* (((&plist :datetime d :repeater r) pts)
(islongp (org-ml-time-is-long d))
(islongp (org-ml-timelist-has-time d))
(sel-date+ (org-x-dag-datetime-shift sel-date 1 'submonth))
((future-limit cur)
(if islongp
@ -2955,7 +2955,7 @@ FUTURE-LIMIT in a list."
(defun org-x-dag-get-deadlines-at (sel-date pts)
(-let* (((&plist :datetime d :repeater r :warning w) pts)
(islongp (org-ml-time-is-long d))
(islongp (org-ml-timelist-has-time d))
((warn-shift warn-shifttype)
(if w w
(let ((f (if islongp 1440 1)))
@ -3465,14 +3465,14 @@ FUTURE-LIMIT in a list."
;; agenda/calendar
(defun org-x-dag-show-gaps (sel-date ids)
(let* ((epoch (org-ml-time-to-unixtime sel-date))
(let* ((epoch (org-ml-timelist-to-unixtime sel-date))
(epoch+ (+ epoch 86400))
(epoch- (- epoch 86400)))
(cl-flet*
((to-interval
(duration datetime)
(when (and (< 0 duration) (org-ml-time-is-long datetime))
(let* ((start (org-ml-time-to-unixtime datetime))
(when (and (< 0 duration) (org-ml-timelist-has-time datetime))
(let* ((start (org-ml-timelist-to-unixtime datetime))
(end (+ start duration)))
(when (or (and (<= epoch start) (<= start epoch+))
(and (<= epoch- start) (<= epoch end)))
@ -3605,7 +3605,7 @@ FUTURE-LIMIT in a list."
(x)
(-let* (((&plist :datetime :id) x)
(duration (or (org-x-dag-id->duration id) 0))
(start (org-ml-time-to-unixtime datetime)))
(start (org-ml-timelist-to-unixtime datetime)))
`(,start ,(+ start (* 60 duration)))))
(format-dtl
(fun dtl conflict)
@ -3621,7 +3621,7 @@ FUTURE-LIMIT in a list."
(can-conflict-p
(dtl)
(-let (((&plist :datetime :id) dtl))
(and (org-ml-time-is-long datetime)
(and (org-ml-timelist-has-time datetime)
(not (org-x-dag-id->is-done-p id))))))
(with-temp-buffer
(org-mode)
@ -3669,7 +3669,7 @@ FUTURE-LIMIT in a list."
;; headline parent links
(defun org-x-dag-section-get-parent-links (children)
(->> (--find (org-x--is-drawer-with-name org-x-drwr-parent-links it) children)
(-some->> (--find (org-x--is-drawer-with-name org-x-drwr-parent-links it) children)
(org-x-dag-drawer-get-parent-links)))
(defun org-x-dag-section-set-parent-links (ids children)
@ -3681,7 +3681,7 @@ FUTURE-LIMIT in a list."
(if ids (cons (org-x-dag-build-parent-link-drawer ids) children) children)))
(defun org-x-dag-headline-get-parent-links (headline)
(->> headline
(-some->> headline
(org-ml-headline-get-contents (org-x-logbook-config))
(org-x-dag-section-get-parent-links)))
@ -3759,12 +3759,11 @@ FUTURE-LIMIT in a list."
(cl-flet
((has-date-p
(date headline)
(-when-let (sched (-some->> (org-ml-headline-get-planning headline)
(org-ml-get-property :scheduled)
(org-ml-timestamp-get-start-time)
(org-x-dag-datetime-split)
(car)
(org-x-dag-date-to-absolute)))
(-when-let (sched (-some--> (org-ml-headline-get-planning headline)
(plist-get it :scheduled)
(org-x-dag-datetime-split it)
(car it)
(org-x-dag-date-to-absolute it)))
(= sched date))))
(--find (has-date-p date it) headlines)))
@ -3868,7 +3867,7 @@ FUTURE-LIMIT in a list."
(org-x-dag-build-planning-id-headline title 4 paragraph ids))
(defun org-x-dag-build-dlp-headline (title paragraph ids datetime)
(let ((pl (org-ml-build-planning! :scheduled datetime)))
(let ((pl (list :scheduled datetime)))
(->> (org-x-dag-build-planning-id-headline title 4 paragraph ids)
(org-ml-headline-set-planning pl))))

View File

@ -66,7 +66,7 @@ nothing."
(with-current-buffer buffer
(widen)
(goto-char pos)
(org-show-context 'agenda)
(org-fold-show-context 'agenda)
,@body
,@get-head-form)
,@update-form

View File

@ -94,7 +94,7 @@ entire subtrees to save time and ignore tasks")
(car)
(org-ml-get-property :value)
(org-ml-timestamp-get-end-time)
(org-ml-time-to-unixtime))))
(org-ml-timelist-to-unixtime))))
(cond
((and first-item-ut first-clock-ut (< first-item-ut first-clock-ut))
first-clock-ut)
@ -294,7 +294,7 @@ the epoch time of the timestamp."
(org-x-headline-is-closed-p)))
(defun org-x-headline-is-created-in-future ()
"Return non-nil if current headline was 'created' in the future.
"Return non-nil if current headline was \"created\" in the future.
This should not happen and is an error if it does, and the
headline is tested analogously to `org-x-headline-is-created-p'
except tests if the timestamp is in the future. Actual returned
@ -321,11 +321,11 @@ timestamp."
(scheduled-ut (-some->> planning
(org-ml-get-property :scheduled)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
(deadline-ut (-some->> planning
(org-ml-get-property :deadline)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
(created-ut (-some->> (org-ml-headline-get-node-property org-x-prop-created hl)
(org-2ft))))
;; not inert if headline is scheduled or deadlined in the future
@ -504,7 +504,7 @@ property."
(defmacro org-x-headline-is-task-with-p (&rest body)
"Return t if all of BODY is t on the current headline.
'it' is bound to the keyword (if any)."
`it' is bound to the keyword (if any)."
(declare (indent 0))
`(-when-let (it (org-x-headline-is-task-p))
(and ,@body t)))
@ -562,7 +562,7 @@ property."
(defun org-x-headline-get-meeting-drawer (drawer-name)
"Return DRAWER-NAME under current headline.
If drawer is present but has no children, return 'none'. If
If drawer is present but has no children, return `none'. If
drawer is present and has a plain-list, return its items as a
list of nodes. If none of these conditions are true, return nil."
(-when-let (d (->> (org-ml-parse-this-headline)
@ -1281,7 +1281,7 @@ latter codes in the list trump earlier ones."
(org-ml-match org-x--first-active-ts-pattern)
(car)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime)))
(org-ml-timelist-to-unixtime)))
(new-status
(cur-status ts)
(let ((new (cond
@ -1528,7 +1528,7 @@ ARG and INTERACTIVE are passed to `org-store-link'."
(node)
(-some->> (org-x-metablock-get-timestamp node)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime)
(org-ml-timelist-to-unixtime)
(< (float-time)))))
(->> (org-x-parse-file-headlines (org-x-get-daily-plan-file) 'all)
(--filter (null (org-ml-headline-get-subheadlines it)))
@ -1614,7 +1614,7 @@ ARG and INTERACTIVE are passed to `org-store-link'."
(ts (-some->> (org-ml-headline-get-planning headline)
(org-ml-get-property :scheduled)
(org-ml-timestamp-get-start-time)
(org-ml-time-to-unixtime))))
(org-ml-timelist-to-unixtime))))
(when (org-ml-is-type 'plain-list first)
(->> (org-ml-get-children first)
(--map (org-x--make-agenda-metaitem headline is-closed ts it))))))
@ -1723,7 +1723,8 @@ This includes unchecking all checkboxes, marking keywords as
(--remove (org-x--is-drawer-with-name org-x-drwr-agenda it))))
;; remove CLOSED planning entry
(org-ml-headline-map-planning*
(-some->> it (org-ml-planning-set-timestamp! :closed nil)))
(plist-put it :closed nil))
;; (-some->> it (org-ml-planning-set-timestamp! :closed nil)))
;; clear item checkboxes
(org-ml-match-map* '(section :any * item)
(org-ml-set-property :checkbox 'off it))
@ -1762,11 +1763,14 @@ timestamp in the contents of the headline will be shifted."
subtree)
(t
(org-ml-headline-map-planning*
(-some->> it
(org-ml-map-property* :scheduled
(when it (org-ml-timestamp-shift offset unit it)))
(org-ml-map-property* :deadline
(when it (org-ml-timestamp-shift offset unit it))))
(-let (((&plist :scheduled s :deadline d) it))
(when s
(->> (org-ml-timelist-shift offset unit s)
(plist-put it :scheduled)))
(when d
(->> (org-ml-timelist-shift offset unit d)
(plist-put it :deadline)))
it)
subtree)))))
(shift
(offset unit subtree)
@ -1785,7 +1789,8 @@ timestamp in the contents of the headline will be shifted."
(--map-when (org-ml-get-property :todo-keyword it)
(assign-id it)
it)))))
(->> (org-ml-clone-node-n n headline)
(->> (-repeat n headline)
(--map (org-element-copy it t))
(--map-indexed (org-x--subtree-shift-timestamps
(* offset (1+ it-index)) unit it))
(-map #'assign-id))))
@ -1878,13 +1883,14 @@ ARG, ask for a range in minutes in place of the second date."
(let* ((t1 (read-date nil))
(t2 (if (equal arg '(4)) (read-duration t1) (read-date t1))))
(if (< t2 t1) (message "Second timestamp earlier than first!")
(let ((s (org-ml-unixtime-to-time-long t1))
(e (org-ml-unixtime-to-time-long t2)))
(let ((s (org-ml-unixtime-to-timelist t t1))
(e (org-ml-unixtime-to-timelist t t2)))
(org-ml-update-this-headline*
(org-ml-headline-map-logbook-clocks* (org-x-logbook-config)
(let ((new-clock (org-ml-build-clock! s :end e)))
(if (org-ml-clock-is-running (car it))
`(,(car it) ,new-clock ,@(cdr it))
(let ((new-clock (org-ml-build-clock! s :end e))
(first-clock (car it)))
(if (and first-clock (org-ml-clock-is-running first-clock))
`(,first-clock ,new-clock ,@(cdr it))
(cons new-clock it)))
it)))))))
@ -1896,7 +1902,7 @@ including those that are inherited."
(let ((atodo (org-ml-get-property :todo-keyword headline))
(atime (-> (substring (cdr org-time-stamp-formats) 1 -1)
(format-time-string))))
(->> (org-ml-clone-node headline)
(->> (org-element-copy headline t)
(org-ml-headline-set-node-property "ARCHIVE_TIME" atime)
(org-ml-headline-set-node-property "ARCHIVE_FILE" afile)
(org-ml-headline-set-node-property "ARCHIVE_OLPATH" apath)
@ -1936,7 +1942,7 @@ and slow."
(org-ml-set-property :todo-keyword org-x-kw-done)
(org-ml-headline-map-planning*
(let ((time (org-ml-unixtime-to-time-long (float-time))))
(org-ml-planning-set-timestamp! :closed time it)))
(plist-put it :closed time)))
;; shift it to the top level
(org-ml-shift-property :level level-shift)
(org-ml-match-map* '(:any * headline)
@ -1963,7 +1969,7 @@ and slow."
(org-ml-unixtime-to-time-long)
(org-ml-build-timestamp!)
(org-ml-to-string)
(org-ml-build-node-property org-x-prop-created))))
(list org-x-prop-created))))
(org-ml-update-this-headline*
(org-ml-headline-map-node-properties* (-snoc it np) it))))
@ -1978,7 +1984,7 @@ If ARG is non-nil use long timestamp format."
(org-ml-unixtime-to-time-short ut))
(org-ml-build-timestamp!)
(org-ml-to-string)
(org-ml-build-node-property org-x-prop-expire))))
(list org-x-prop-expire))))
(org-ml-update-this-headline*
(org-ml-headline-map-node-properties* (cons np it) it)))))
@ -1986,7 +1992,7 @@ If ARG is non-nil use long timestamp format."
"Set days-to-live of the current headline."
(interactive)
(let ((np (->> (org-x--read-number-from-minibuffer "Days to live" t)
(org-ml-build-node-property org-x-prop-days-to-live))))
(list org-x-prop-days-to-live))))
(org-ml-update-this-headline*
(org-ml-headline-map-node-properties* (cons np it) it))))
@ -2127,7 +2133,7 @@ This will return matching matcher form for FILTER and TYPE
where TYPE is not in the regular `org-agenda-filter-make-matcher'
function. This is intended to be used as :before-until advice and
will return nil if the type is not valid (which is currently
'property')"
`property')"
(when (eq type 'property)
(-some->> (-map #'org-x-agenda-filter-make-property-matcher-form filter)
(cons 'and))))

View File

@ -1,111 +1,114 @@
(("ESS" . "950bf61054bd96d2203ac0457792c0af8dfba721")
(("ESS" . "dbebca483e7386fa5c17505ab444c817f6926bd4")
("Highlight-Indentation-for-Emacs" . "d88db4248882da2d4316e76ed673b4ac1fa99ce3")
("ace-window" . "77115afc1b0b9f633084cf7479c767988106c196")
("anaconda-mode" . "f900bd7656a03aa24ef3295251f266736f7756eb")
("annalist.el" . "e1ef5dad75fa502d761f70d9ddf1aeb1c423f41d")
("auctex" . "ca8c9077c4c889cc11d150af9f0d9bd5914d702e")
("auctex" . "bf69bed39aac9903422549bc55cab3ca248cfc5a")
("auth-source-xoauth2" . "5d1adfa649bb5a9df20a2fa89f235a55a64b52e4")
("avy" . "be612110cb116a38b8603df367942e2bb3d9bdbe")
("avy" . "933d1f36cca0f71e4acb5fac707e9ae26c536264")
("bats-mode" . "fa88930b1baba101ae6474f289a239a236a7d19f")
("beacon" . "85261a928ae0ec3b41e639f05291ffd6bf7c231c")
("biblio.el" . "ee52f6cda82ea6fbc3b400e7b12132595cc0374c")
("bind-key" . "ae3197044f47f6a83897dd70762cb58c6efcffa1")
("blacken" . "3c6eb86ad871ca14fcfd4e5c0e7b285afa1f1f71")
("c-eldoc" . "f4ede1f37f6de583376669735326367d84a0a917")
("citeproc-el" . "54184baaff555b5c7993d566d75dd04ed485b5c0")
("clang-format" . "9f4358fcc8b04018cc1ed46fcc96fc7bfa361a47")
("clang-format" . "f01d16be89a4421169c421d25cfdddb3ad62460f")
("company-anaconda" . "169252fca79a79da41ef22f2ec0eab0cf1313966")
("company-auctex" . "9400a2ec7459dde8cbf1a5d50dfee4e300ed7e18")
("company-c-headers" . "9d384571b1190e99d0a789e5296176d69a3d0771")
("company-irony" . "b44711dfce445610c1ffaec4951c6ff3882b216a")
("company-math" . "3eb006874e309ff4076d947fcbd61bb6806aa508")
("company-mode" . "1321e285a54dfe43cae71f52e58bff4f0c8c161d")
("compat" . "99d74e635b76c3fa0b8403391e9d2efbd29f9901")
("conda.el" . "ce748a53f9c7d7a7d112632d32c848d6e5482e18")
("company-mode" . "0ae7c293112248a0c36377d6859a95d216ae5e96")
("compat" . "d21b1cde40a71f07ba07f95a2e461813b822bdcc")
("conda.el" . "05de0c8f0cf336d90c044446aaa066ee13001b83")
("csv-mode" . "6979fc18ebe133cfe2fca02efda9a9f0cd13428a")
("dash.el" . "1de9dcb83eacfb162b6d9a118a4770b1281bcd84")
("delight" . "15acb0f0ba400c470e378f9984b315f9e02c1122")
("dhall-mode" . "87ab69fe765d87b3bb1604a306a8c44d6887681d")
("dired-du" . "c16cad8c40a022a03dee1956a15ff44d1e42dc07")
("dired-hacks" . "e9e408e8571aee5574ca0a431ef15cac5a3585d4")
("dockerfile-mode" . "39a012a27fcf6fb629c447d13b6974baf906714c")
("ebib" . "5ea510a1e4ab17a442352d0212777da5f78d4be2")
("el-get" . "c0713e8d8e8ad987fe1283d76b9c637a10f048ef")
("dockerfile-mode" . "4d893bd2da15833ce056332e6c972d5d93e78f04")
("ebib" . "5dac71546bb8541ee67104c17df6fc3ae5e364db")
("el-get" . "847901f07bdf67763fa3a6c0fb057048cd58603b")
("elpy" . "c40bab559fe77dcef6b90d5502eba1ecd566e86d")
("emacs-async" . "e1d46f97a56e0c57206bd1ea31d04311097a8cbb")
("emacs-buttercup" . "dfbef2177209e3a045e981b7d2956ec46ce3b25b")
("emacs-dashboard" . "187699e2d80f6a3b0ec7b2fb2e1d7ece2712208f")
("emacs-format-all-the-code" . "f8feea08fef7ed542b8e676e90445d57ebd2c458")
("emacs-htmlize" . "ed5e5b05fd260e8f161a488d56f10e7f6e01fb75")
("emacs-language-id" . "44452e4f7962aca41cc2539fce1d27799d6e656c")
("emacs-async" . "863b3366a0077279646bf9eec1f97dba6c052440")
("emacs-buttercup" . "bf01a33f8bc2d3664121d3b20f7496e67ce55e6a")
("emacs-calfw" . "03abce97620a4a7f7ec5f911e669da9031ab9088")
("emacs-dashboard" . "9479466d39652a8e32b74ee83822421fa08024d9")
("emacs-format-all-the-code" . "9ae47456dad2925e4d41f58bd2c864b87f82aa8b")
("emacs-htmlize" . "8e3841c837b4b78bd72ad7f0436e919f39315a46")
("emacs-language-id" . "dbfbc4903ffb042552b458fac76ee9f67a022036")
("emacs-refactor" . "cac1b52932926f56d7f6d2923732d20bbd20670d")
("emacs-reformatter" . "0d29a04d69d47599e2cb7f1a8f8e897a2b592921")
("emacs-reformatter" . "8962e1dd0c949997413380ea1f8d8a25ada5f624")
("emacs-request" . "01e338c335c07e4407239619e57361944a82cb8a")
("emacs-web-server" . "3982c55e9061475038a3ccd61aecb2de3d407cec")
("emacs-which-key" . "38d4308d1143b61e4004b6e7a940686784e51500")
("emacsmirror-mirror" . "8cbbdaa750c897d05ee71980834699a7d7c2d208")
("evil" . "5db0bdc7dcd9300b983526d37cbe480f35e36211")
("emacsmirror-mirror" . "dbe7f4ef5215dc6b6592eee6a56acc1d48671e6d")
("evil" . "b7ab3840dbfc1da5f9ad56542fc94e3dab4be5f1")
("evil-ReplaceWithRegister" . "91cc7bf21a94703c441cc9212214075b226b7f67")
("evil-collection" . "772571fc6762b6cd1d35cc869e266de9a5c6022b")
("evil-collection" . "2c4e2aca1ad7be8eb41e4cb9b58b8023d8a5fd8b")
("evil-commentary" . "c5945f28ce47644c828aac1f5f6ec335478d17fb")
("evil-org-mode" . "b1f309726b1326e1a103742524ec331789f2bf94")
("evil-surround" . "da05c60b0621cf33161bb4335153f75ff5c29d91")
("f.el" . "1e7020dc0d4c52d3da9bd610d431cab13aa02d8c")
("f.el" . "931b6d0667fe03e7bf1c6c282d6d8d7006143c52")
("fill-column-indicator" . "c35f9de072c241699b57bcb46da84bed5af29cfe")
("flycheck" . "7a6398ea3538a898eba0276f0f89b2f878325a89")
("flycheck" . "5217e0e02f487d70e3d418e5e6ce884fc9711511")
("flycheck-clang-analyzer" . "646d9f3a80046ab231a07526778695d5decad92d")
("flycheck-haskell" . "b7c4861aa754220b7d0cfc05aa0895bb35665683")
("flycheck-package" . "75efa098cf17dc14c363e2ca9b68afdac7766b5b")
("flycheck-haskell" . "0977232112d02b9515e272ab85fe0eb9e07bbc50")
("flycheck-package" . "a52e4e95f3151898b36739dfdb4a98b368626fc0")
("flyspell-correct" . "1e7a5a56362dd875dddf848b9a9e25d1395b9d37")
("gnu-elpa-mirror" . "3d0759ef4792b6461f2979a4e70e1c819df7283a")
("gnu-elpa-mirror" . "97f6fd99aa7184c6bcd23cffc7653b8212479cc6")
("goto-chg" . "72f556524b88e9d30dc7fc5b0dc32078c166fda7")
("graphviz-dot-mode" . "8ff793b13707cb511875f56e167ff7f980a31136")
("haskell-mode" . "727f72a2a4b8e4fd0a7b62129668baea55a2c3e0")
("helm-bibtex" . "8b71b4f5ce62eeaf18067f57faaddc06449fbe1c")
("haskell-mode" . "1a285fc4c50ca74bb5cd9b2a8c1a46a64a77384a")
("helm-bibtex" . "6064e8625b2958f34d6d40312903a85c173b5261")
("ht.el" . "1c49aad1c820c86f7ee35bf9fff8429502f60fef")
("hydra" . "317e1de33086637579a7aeb60f77ed0405bf359b")
("iedit" . "27c61866b1b9b8d77629ac702e5f48e67dfe0d3b")
("impatient-mode" . "a4e4e12852840996b027cb8e9fb2b809c37a0ee3")
("inf-ruby" . "b234625c85a48cc71e7045f5d48f079f410d576a")
("inheritenv" . "bac62ca6324828623cf8ce5a3d6aee0fcb65d620")
("inf-ruby" . "6399a3668224aa48423c54e81383f73e5e39439a")
("inheritenv" . "b9e67cc20c069539698a9ac54d0e6cc11e616c6f")
("irony-mode" . "40e0ce19eb850bdf1f77225f11713cc816250d95")
("jinja2-mode" . "03e5430a7efe1d163a16beaf3c82c5fd2c2caee1")
("js-comint" . "ef2ccccad5740f3d8b5295f52a35df4f62471480")
("js-comint" . "a2e6f01b999e26047808c1720b7be0805afc7cb6")
("json-mode" . "77125b01c0ddce537085201098bea9b4b8ba6be3")
("json-snatcher" . "b28d1c0670636da6db508d03872d96ffddbc10f2")
("let-alist" . "4e05e158612f360f6080b1349d3962b1c8fee902")
("let-alist" . "8141e7c941105c92e89bba44e73aae6cdd962b49")
("lispy" . "fe44efd21573868638ca86fc8313241148fabbe3")
("list-utils" . "f02dcef36330871855346f9eab97eef58d323d9a")
("list-utils" . "bbea0e7cc7ab7d96e7f062014bde438aa8ffcd43")
("lua-mode" . "d074e4134b1beae9ed4c9b512af741ca0d852ba3")
("magit" . "61f6a778ab5b0ca97069778a5955ae527996cd0f")
("markdown-mode" . "8a7773f87733866a961ea4c518a4a2f283f21970")
("magit" . "1e17181a21ffaec20c9540f413bea04ca20d65f1")
("markdown-mode" . "b8637bae075231d70fe7f845305eaba2c0240d89")
("math-symbol-lists" . "ac3eb053d3b576fcdd192b0ac6ad5090ea3a7079")
("melpa" . "a21e230a1e8034076b2a271809ccf613476eeea7")
("melpa" . "dba758aada61346108e9c34b9fef2eb02dd55433")
("nix-mode" . "719feb7868fb567ecfe5578f6119892c771ac5e5")
("no-littering" . "8b07314d2f0594ff22bf798d9a5f5bf44b4dd4cd")
("nongnu-elpa" . "a9a649210a8d8b9295b5a1d0c7b60a77db03c14c")
("no-littering" . "bbcbdcdce968a0ac7c293314e1aa7dfdda63a30c")
("nongnu-elpa" . "4b8b3633c7e29412c89f1c9d6ad7a951772be758")
("org" . "233a0ced97366090c31ef94562879bb2f729b120")
("org-bullets" . "767f55feb58b840a5a04eabfc3fbbf0d257c4792")
("org-ml" . "f57336a9126a168ad32ccce017c072474555395a")
("org-ref" . "fd178abf12a85f8e12005d1df683564bdc534124")
("org-sql" . "43376abf46b897a9a862cfcc1c087f4b8688634c")
("org-super-agenda" . "05a710065af5ee4b3982f9619f864f7af12ca1d3")
("org-ref" . "732a20bd236fd02db4a651da29f87f87f458a54a")
("org-sql" . "3dbf11d692cf0d5e64235ad4041ed0b5a6775064")
("org-super-agenda" . "c07e35416ce749b42cbb70ff8d4e814362111bb5")
("origami.el" . "e558710a975e8511b9386edc81cd6bdd0a5bda74")
("outline-magic" . "2a5f07417b696cf7541d435c43bafcc64817636b")
("ox-pandoc" . "34e6ea97b586e20529d07158a73af3cf33cdd1d5")
("package-lint" . "972dd8403ac8d2d43f298ef89a6b118e49c7355f")
("paredit" . "037b9b8acbca75151f133b6c0f7f3ff97d9042e5")
("parsebib" . "ace9df707108b17759c004c7387655277122d4c1")
("package-lint" . "d2846f0c57931195946d771a900906e1a16d394e")
("paredit" . "af075775af91f2dbc63b915d762b4aec092946c4")
("parsebib" . "c0ee4d5f10bf801af03f633b6b73ced4a0ffead7")
("password-store" . "b5e965a838bb68c1227caa2cdd874ba496f10149")
("pcre2el" . "b4d846d80dddb313042131cf2b8fbf647567e000")
("pdf-tools" . "30b50544e55b8dbf683c2d932d5c33ac73323a16")
("php-mode" . "59814bd80c59894022bc5950fb3bdf02420e8a89")
("pkgbuild-mode" . "8ef396d8fa9187b65c065a6bc2ca15dfaf3255df")
("php-mode" . "31f702ee2de35d514fb633c0c37531cb648bff70")
("pkgbuild-mode" . "8c31b24e5979fddf2411456c8957f41f06ae5714")
("poly-R" . "8024e852cfca642dea2045a41b2033baa2f1f9a5")
("poly-markdown" . "98695eb7ca4ca11dcec71a1cab64903bbf79b4d3")
("poly-noweb" . "3b0cd36ca9a707e8a09337a3468fa85d81fc461c")
("polymode" . "ca060e081a1f849a880732670dc15370ac987b89")
("popup-el" . "c83d6e5f5fa693e08a542ea9ad7c06eced652de9")
("powerline" . "c35c35bdf5ce2d992882c1f06f0f078058870d4a")
("projectile" . "01fb6a5ef023bcfc52b209586dcb4fd13db00218")
("projectile" . "d18e308ea9b7473b69f904d40ed4835b3e34d5e2")
("pythonic" . "c1e5643e044f1faaf6ecfadc719b981c048aeb79")
("pyvenv" . "31ea715f2164dd611e7fc77b26390ef3ca93509b")
("queue" . "8df1334d54d4735d2f821790422a850dfaaa08ef")
@ -118,19 +121,19 @@
("seq" . "da86da9bf111f68fb81efd466d76d53af5aebc00")
("snakemake-mode" . "4ad41da69e4b95b38a3d3273874c44caab20cc56")
("spaceline" . "086420d16e526c79b67fc1edec4c2ae1e699f372")
("spacemacs-theme" . "d02edec79404e807445b62d0d2fc1a6fbcc10c71")
("straight.el" . "88e574ae75344e39b436f863ef0344135c7b6517")
("spacemacs-theme" . "6c74684c4d55713c8359bedf1936e429918a8c33")
("straight.el" . "33fb4695066781c634ff1c3c81ba96e880deccf7")
("string-inflection" . "617df25e91351feffe6aff4d9e4724733449d608")
("sudo-edit" . "74eb1e6986461baed9a9269566ff838530b4379b")
("swiper" . "2a25a6fb5b081cb141c5eccac8ee58ab1feeb747")
("swiper" . "8dc02d5b725f78d1f80904807b46f5406f129674")
("tablist" . "fcd37147121fabdf003a70279cf86fbe08cfac6f")
("toc-org" . "6d3ae0fc47ce79b1ea06cabe21a3c596395409cd")
("transient" . "3d3f8711d4f6a6ff7f53bc22e465ec82587c62ed")
("transient" . "4de5812992ef93fcd80ef1d12a6e1db7f7cd315d")
("ts.el" . "552936017cfdec89f7fc20c254ae6b37c3f22c5b")
("use-package" . "a6e856418d2ebd053b34e0ab2fda328abeba731c")
("with-editor" . "8c550d9e799a0baedb2164471e7ed19fc15d9196")
("use-package" . "fc8449bb593de8fce0a8bdd4ee2cb78219cf8c76")
("with-editor" . "57f20bdb0d50256acdd12019aaa42b609204699b")
("xterm-color" . "2ad407c651e90fff2ea85d17bf074cee2c022912")
("yaml-mode" . "7b5ce294fb15c2c8926fa476d7218aa415550a2a")
("yasnippet" . "eb5ba2664c3a68ae4a53bb38b85418dd131b208f")
("yaml-mode" . "d91f878729312a6beed77e6637c60497c5786efa")
("yasnippet" . "fe1f4e0e96ce42d8668920335eb22c3c009dab3e")
("zoutline" . "32857c6c4b9b0bcbed14d825a10b91a98d5fed0a"))
:gamma