Interactive substitute/replace script