Hi,
I'm not sure, there is solution exist for this problem. I'm facing problem in calling a unix script from awk code. Here is code
nawk -F'=' '
BEGIN { }
function runtest(string)
{
LINE
}
/^[.*\]/ { # getting module name
t=$1
module=substr(t,2,(length(t)-2))
runtest(module)
}
/INCLUDE/ {
}
/LEVEL/ {
}
/LOG_LEVEL/ {
}
END {}
' test-suite.cfg
<<<<<<<<<<<<<<>>>>>>>>>>
Content in the test-suite.cfg
[module1]
INCLUDE=Y
LEVELS=BASIC,INTER,ADVANCE
LOG_LEVEL=10
REPROT=module1.log
...
..
<<<<<<<<<<<<<<<<>>>>>>>>>>
In the "LINE", i'm trying to call unix script to start test-suite based on the input arguments such as "module, level, leg_level...".
I tried LINE with following but nothing worked
ATT 1. ./test-suite/module/basic/start.ksh
Error:
context is
>>> ./test-suite/module/basic/start <<< .ksh
nawk: illegal statment at source line 10 in function
Tried with escape for "." also didnt work
ATT 2. test-suite/module/basic/start
Error : nawk division by zero
Basicaly, i want to secute the script based on the input argument and get the test results also.
Kindly help me to resolve this problem.
Thanks and Regards,
Balaji