added --existing option, similar to one suggested by Gildas Quiniou <gildas@stip.fr>