Formatting Report and Reading data and fetching the details from contents file

Data

I was trying to write shell script which will be return the output in the below format

First i was trying to do these using sed.

sed -n '/.ksh/p' mainksh.ksh
sed -e 's/[^"]*\(.*\)/\1/g' mainksh.ksh

$RUN_DIR, $SUB_DIR and the variables which will be defined in the profile file.

when i am trying to use the below command by merging above 2 commands, it is printing the values twice and even it is printing #/usr/ksh line

sed -n -e '/.ksh/p; s/[^"]*\(.*\)/\1/g' mainksh.ksh