sed substitua primeiro no arquivo
sed '0,/REPLACESTHIS/s//WITHTHAT/' myfile.txt
garzj
sed '0,/REPLACESTHIS/s//WITHTHAT/' myfile.txt