Sed with = as delimiter

sedtext processing

I'm having a hard time figuring out how to use sed to cut text before a certain delimiter.

I'm receiving output from echo that returns something similar to:

valueA=TEXT

I would like to have sed cut the text before = and leaving only TEXT.

Any tips on how it can be done?

Best Answer

You can also use cut :

cut -d= -f2- <<< "$yourvar"

or

some_command | cut -d= -f2-
  • -d= sets the delimiter to =
  • -f2- takes the second field and all the following ones
Related Question