fork download
  1. #!/bin/bash
  2. s='_OA ............. [6712227000168]
  3. _OA Tasdsd, OA .. [91][355016]
  4. _OA Tasdsd, DA .. [91][5512987000]'
  5. awk '/_OA/ { match($0,/\[[[:digit:]]{4,13}]/);print substr($0,RSTART+1,RLENGTH-2)}' <<< "$s"
Success #stdin #stdout 0.01s 5440KB
stdin
Standard input is empty
stdout
6712227000168
355016
5512987000