Skip to content

Commit

Permalink
Accept OPML 1.0 and some other things
Browse files Browse the repository at this point in the history
Not sure how safe OPML 1.0 is with conversion, but it seems to work with
output from at least one tool that exports it.

This also accepts an encoding declaration on the xml header, and
steps past a comment intervening between the header and the start
of OPML (I'm not familiar with Emacs regexp, the latter tweak may not
really be needed).

Signed-off-by: Eric Davis <eric@davising.com>
Closes #5
  • Loading branch information
fbennett authored and Eric Davis committed Aug 9, 2014
1 parent 03c8232 commit f69c2ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion org-opml.el
Expand Up @@ -2,7 +2,7 @@
;;
;; Change "~/src/org-opml/opml2org.py" to wherever that file is located.
(add-to-list 'format-alist '(opml "Outline Processor Markup Language"
"<[?]xml version=\"1.0\"[?]>[\n]?.*[\n]?<opml version=\"2.0\">"
"<[?]xml version=\"1.0\"[^>]*[?]>[\n]?.*[\n]?.*[\n]?<opml version=\"[1|2].0\">"
"~/src/org-opml/opml2org.py" opml-encode t))

;; If it ends with .opml, use `opml-encode' when saving.
Expand Down

0 comments on commit f69c2ee

Please sign in to comment.