Implement 'visit' command