Why does the following does not work?
INTERNAL_NUM=$(grep -E '\s*internal_num\s*=' file.xml |sed -E 's/internal_num\s*=\s*([0-9]\+)/\1/') echo "$INTERNAL_NUM"
I would like to print out the actual number but it prints:
internal_num = 1234
grep command prints
internal_num = 1234 so that part is fine. It is the pipe to
sed that does not work.