fix bug with zero length values
This commit is contained in:
@@ -60,10 +60,11 @@ else:
|
|||||||
for l in in_reader:
|
for l in in_reader:
|
||||||
for p in pairs:
|
for p in pairs:
|
||||||
value=p[1]
|
value=p[1]
|
||||||
if value[0]=="@":
|
if len(value)>0:
|
||||||
value=open(value[1:],'rt').read()
|
if value[0]=="@":
|
||||||
elif value[0:2]=="\\@":
|
value=open(value[1:],'rt').read()
|
||||||
value=value[1:]
|
elif value[0:2]=="\\@":
|
||||||
|
value=value[1:]
|
||||||
l=l.replace(p[0],value)
|
l=l.replace(p[0],value)
|
||||||
if options.env:
|
if options.env:
|
||||||
var_list=[m.group(0) for m in re.finditer('\${[^ ]+}', l)]
|
var_list=[m.group(0) for m in re.finditer('\${[^ ]+}', l)]
|
||||||
|
|||||||
Reference in New Issue
Block a user