smdahlen/vagrant-hostmanager — pull request #45 by bdcribbs (2013-11-02 21:03:58+00:00)
Title:  #44 Handle destroyed machines in update_file

Keep track of machines that have been destroyed (they have a nil id).
Do not include them when updating the hosts file.

Since it is impossible to match on id, this is accomplished by matching
the exact ip / hostname / alias. If any of these have been altered
since the entry was created the entry will not be removed from the hosts
file.

Potentially, this could be relaxed to only match on ip / hostname pairs.