/ Published in: Bash
join characters inside file by extracting keyword which separate by newline and special characters by including desired numbers characters on right and left
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
# i used hexdump to find out the special characters # hexdump -c file # below commands will extract the pattern include 100 characters on right and left from the keyword pattern tr -d '[[:space:]]' < file | grep -o '/\{0,100\}PATTERN.\{0,100\}'