fork(1) download
  1. #!/bin/bash
  2. text="1.23.23.45 This is what I want"
  3. rx='(,? ?(\.?[0-9]{1,3}){4})+ (.*)'
  4. if [[ $text =~ $rx ]]; then
  5. echo "${BASH_REMATCH[3]}"
  6. else
  7. echo "No match!"
  8. fi
Success #stdin #stdout 0s 4464KB
stdin
Standard input is empty
stdout
This is what I want