updates txt file