[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master ad75461 017/135: Use existing org-xor instead of new funct
From: |
Ian Dunn |
Subject: |
[elpa] master ad75461 017/135: Use existing org-xor instead of new function |
Date: |
Mon, 17 Feb 2020 10:52:45 -0500 (EST) |
branch: master
commit ad75461e957ffe427d2c87cc49cb1cbcd13200bd
Author: Ian D <address@hidden>
Commit: Ian D <address@hidden>
Use existing org-xor instead of new function
* org-edna.el (org-edna--xor): Removed.
(org-edna-condition/todo-state):
(org-edna-condition/headings):
(org-edna-condition/variable-set):
(org-edna-condition/has-property): Use org-xor
---
org-edna.el | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/org-edna.el b/org-edna.el
index e75127e..a605179 100644
--- a/org-edna.el
+++ b/org-edna.el
@@ -393,10 +393,6 @@ IDS are all UUIDs as understood by `org-id-find'."
;; This means that we want to take the exclusive-or of condition and neg.
-(defsubst org-edna--xor (lhs rhs)
- (or (and lhs (not rhs))
- (and (not lhs) rhs)))
-
(defun org-edna-condition/done (neg)
(when-let ((condition
(if neg
@@ -406,23 +402,23 @@ IDS are all UUIDs as understood by `org-id-find'."
(defun org-edna-condition/todo-state (neg state)
(let ((condition (string-equal (org-entry-get nil "TODO") state)))
- (when (org-edna--xor condition neg)
+ (when (org-xor condition neg)
(org-get-heading))))
;; Block if there are headings
(defun org-edna-condition/headings (neg)
(let ((condition (not (seq-empty-p (org-map-entries (lambda nil t))))))
- (when (org-edna--xor condition neg)
+ (when (org-xor condition neg)
(buffer-name))))
(defun org-edna-condition/variable-set (neg var val)
(let ((condition (string-equal (symbol-value (intern var)) (read val))))
- (when (org-edna--xor condition neg)
+ (when (org-xor condition neg)
(format "%s %s= %s" var (or neg "=") val))))
(defun org-edna-condition/has-property (neg prop val)
(let ((condition (string-equal (org-entry-get nil prop) val)))
- (when (org-edna--xor condition neg)
+ (when (org-xor condition neg)
(org-get-heading))))
- [elpa] master updated (487ad1b -> bf8ecda), Ian Dunn, 2020/02/17
- [elpa] master 567e982 007/135: Added package requirements, Ian Dunn, 2020/02/17
- [elpa] master a943aa6 008/135: Added more custom IDs to documentation, Ian Dunn, 2020/02/17
- [elpa] master 21d2019 006/135: Added has-property condition, Ian Dunn, 2020/02/17
- [elpa] master 0e5fd41 004/135: Added .bzrignore., Ian Dunn, 2020/02/17
- [elpa] master 3a4cca9 003/135: Added Makefile., Ian Dunn, 2020/02/17
- [elpa] master 01c50c0 002/135: Make all finders return lists of markers, Ian Dunn, 2020/02/17
- [elpa] master 5010097 005/135: Added initial documentation, Ian Dunn, 2020/02/17
- [elpa] master 18814ca 001/135: Initial Commit., Ian Dunn, 2020/02/17
- [elpa] master 1fb6dcf 013/135: Added chain action, Ian Dunn, 2020/02/17
- [elpa] master ad75461 017/135: Use existing org-xor instead of new function,
Ian Dunn <=
- [elpa] master adbff7e 019/135: Remove duplicate targets, Ian Dunn, 2020/02/17
- [elpa] master 6886b8a 026/135: Fixed chain-find, Ian Dunn, 2020/02/17
- [elpa] master 55283ff 015/135: Renamed to Org-Edna., Ian Dunn, 2020/02/17
- [elpa] master d348102 025/135: Added file for tests, Ian Dunn, 2020/02/17
- [elpa] master 71cdc0a 027/135: Fixed parsing bug, Ian Dunn, 2020/02/17
- [elpa] master 6b9a676 031/135: Added documentation for each condition, Ian Dunn, 2020/02/17
- [elpa] master 71e00e4 036/135: Fixed consideration handling, Ian Dunn, 2020/02/17
- [elpa] master 9f27779 014/135: Clarified use of case-fold-search in `org-bat--handle-planning', Ian Dunn, 2020/02/17
- [elpa] master 13e752b 021/135: Fix uses of substring, Ian Dunn, 2020/02/17
- [elpa] master 3937f31 009/135: Fixed headings condition, Ian Dunn, 2020/02/17