use awk regex operator
This commit is contained in:
parent
aad4844bb5
commit
450f76aa49
3
HISTORY
3
HISTORY
@ -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
|
||||
|
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user