Test your websites with this simple GUI based scripted webtester. Generate simple testscripts directly from surfng on the webpage, enhance them with your commands, with variables, loops, checks, … and finally run automated web tests.
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.3 KiB
44 lines
1.3 KiB
#!/bin/sed -nsf |
|
|
|
# begin of file, declare file |
|
1{ |
|
/@file/!{ # no file definition yet, add it |
|
x |
|
s,^, @file\n, |
|
x |
|
} |
|
} |
|
|
|
# line with doxygen comment (defined as ## at begin of line) |
|
/^##\( \|$\)/{ |
|
s/##\( \|$\)/ / # replace ## comments by 4 spaces indent |
|
H; d # hold, evaluate later |
|
} |
|
|
|
# variable definition |
|
/^set/{ |
|
s,^set \+\([^ =]\+\)\( *= *\(.*\)\)\?,/** @var \1, # prepend variable decl |
|
G # append hold buffer |
|
s,$, */\n, # append end of comment |
|
p; z; x; d # clear buffer, next line |
|
} |
|
|
|
# function definition |
|
/^function/{ |
|
s,^function \+\([^ ]\+\) *\(.*\)\?,/** @fn \1(\2), # prepend function decl |
|
G # append hold buffer |
|
s,$, */\n, # append end of comment |
|
p; z; x; d # clear buffer, next line |
|
} |
|
|
|
# default for non matching lines - print buffer |
|
{ |
|
z; x; # get and clear buffer |
|
/^$/!{ # only if buffer is not empty |
|
s,^\n,, # remove first newline |
|
s,^\( \)\?,/** , # prepend doxygen comment start |
|
s,$, */\n, # append end of comment |
|
p; d |
|
} |
|
} |
|
|
|
|