use awk regex operator

This commit is contained in:
nuex 2011-10-18 01:12:21 -04:00
parent aad4844bb5
commit 450f76aa49
3 changed files with 5 additions and 2 deletions

View File

@ -1,3 +1,6 @@
0.1.1 / 2011-10-18
* use awk regex operator
0.1 / 2011-10-08
- First release
* supports directories with spaces

View File

@ -1 +1 @@
0.1
0.1.1

View File

@ -67,7 +67,7 @@ END {
function bind_data(txt, tag, key) {
if (match(txt, /{{([^}]*)}}/)) {
tag = substr(txt, RSTART, RLENGTH)
match(tag, /(\w|[?]).*[^}]/)
match(tag, /([[:alnum:]_]|[?]).*[^}]/)
key = substr(tag, RSTART, RLENGTH)
gsub(tag, data[key], txt)
return bind_data(txt, data)