Updates the working directory