remove part of the file