I have example string like
Test \"checkin_resumestorevisit - Online_V2.mt\" Run
and i want to extract the text between the two quotes in bash. I tried
In order to extract the substring between quotes you can use one of these alternatives:
Alternative 1:
SUBSTRING=`echo "$SUBSTRING" | cut -d'"' -f 2`
Alternative 2:
SUBSTRING=`echo "$SUBSTRING" | awk -F'"' '{print $2}'`
Alternative 3:
set -f;IFS='"'; SUBSTRING=($SUBSTRING); SUBSTRING=${SUBSTRING[1]};set +f