Permalink
Browse files

Fixed include in test file. Fixed single letter map key support.

  • Loading branch information...
1 parent 3e4ad4c commit 8f7d83a6fa9c6e630da6486a2e87cbe4b093a697 @h4evr committed Jan 21, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 tests/index.html
  2. +1 −1 yamlparser.js
View
@@ -3,7 +3,7 @@
<head>
<meta charset="UTF-8">
<title>YAML Parser</title>
- <script type="text/javascript" src="../src/yaml.js"></script>
+ <script type="text/javascript" src="../src/yamlparser.js"></script>
<script type="text/javascript">
window.onload = function() {
var test1 = YAML.eval("---\n- one\n- two");
View
@@ -47,7 +47,7 @@ var YAML =
"map" : new RegExp("\\{\\s*(.*)\\s*\\}"),
"key_value" : new RegExp("([a-z0-9_-][ a-z0-9_-]*):( .+)", "i"),
"single_key_value" : new RegExp("^([a-z0-9_-][ a-z0-9_-]*):( .+?)$", "i"),
- "key" : new RegExp("([a-z0-9_-][ a-z0-9_-]+):( .+)?", "i"),
+ "key" : new RegExp("([a-z0-9_-][ a-z0-9_-]*):( .+)?", "i"),
"item" : new RegExp("^-\\s+"),
"trim" : new RegExp("^\\s+|\\s+$"),
"comment" : new RegExp("([^\\\'\\\"#]+([\\\'\\\"][^\\\'\\\"]*[\\\'\\\"])*)*(#.*)?")

0 comments on commit 8f7d83a

Please sign in to comment.