I need to replace the pattern ### with the current line number.
###
I managed to Print in the next line with both AWK and SED.
sed -n \"/###/{
Simple awk oneliner:
awk
awk '{gsub("###",NR,$0);print}'