update and add a file