Added method for name matching

Also changed over file writing system
Fixed bug with config writing twice