Skip to content

Commit 35e1b1d

Browse files
committed
fix: asciidoc yaml parsing
Fixes the issue as described in #192 by checking the triple dash to be prefixed by either the start of the document, or the start of a new line. This does still allow for some content before the actual yaml.
1 parent 6965b26 commit 35e1b1d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/io/perun/yaml.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
(:import [flatland.ordered.map OrderedMap]
88
[flatland.ordered.set OrderedSet]))
99

10-
(def ^:dynamic *yaml-head* #"---\r?\n")
10+
(def ^:dynamic *yaml-head* #"(?:^|\n)---\r?\n")
1111

1212
(defn substr-between
1313
"Find string that is nested in between two strings. Return first match.

0 commit comments

Comments
 (0)