a way to replace section within file