How can I extract a substring after a certain string in ksh?
问题 If I have a string like this: The important variable=123 the rest is not important. I want to extract the "123" part in ksh. So far I have tried: print awk ' {substr($line, 20) }' | read TEMP_VALUE (This 20 part is just temporary, until I work out how to extract the start position of a string.) But this just prints awk ' {substr($line, 20) }' | read TEMP_VALUE (though this format does work with code like this: print ${line} | awk '{print $1}' | read SINGLE_FILE ). Am I missing a simple