summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <n.goaziou@gmail.com>2013-12-15 15:17:24 +0100
committerNicolas Goaziou <n.goaziou@gmail.com>2013-12-15 15:17:24 +0100
commit29c02c3810e5115eb53fd81cc64c1820fe844c1f (patch)
tree2312e0e8b6c2d97c3b18be95fda5de81890aeca4
parent18d3057e6208642b2fe6af327892861a6ebf63aa (diff)
downloadorg-mode-29c02c3810e5115eb53fd81cc64c1820fe844c1f.tar.gz
ox-org: Remove attr_backend keywords
* lisp/ox-org.el (org-org-identity): Since back-end specific keywords are stripped from output, also remove attr_backend keywords.
-rw-r--r--lisp/ox-org.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/ox-org.el b/lisp/ox-org.el
index 86f1b60..df3caaa 100644
--- a/lisp/ox-org.el
+++ b/lisp/ox-org.el
@@ -114,7 +114,10 @@ setting of `org-html-htmlize-output-type' is 'css."
(defun org-org-identity (blob contents info)
"Transcode BLOB element or object back into Org syntax.
CONTENTS is its contents, as a string or nil. INFO is ignored."
- (org-export-expand blob contents t))
+ (let ((case-fold-search t))
+ (replace-regexp-in-string
+ "^[ \t]*#\\+ATTR_[-_A-Za-z0-9]+:\\(?: .*\\)?\n" ""
+ (org-export-expand blob contents t))))
(defun org-org-headline (headline contents info)
"Transcode HEADLINE element back into Org syntax.