Question: I’m using Git on Mac 10.9.5 and would like to pull down the latest version of what is in a branch. I don’t care about any local changes I’ve made — I’m happy to abandon all of those. Right now when I run

```
git pull origin branch-name

```

I get errors like

```
Please, commit your changes or stash them before you can merge.
error: The following untracked working tree files would be overwritten by merge:
    src/main/java/com/myco/classroom/dto/ClassroomCourseDto.java
    src/main/java/com/myco/clever/dto/CleverClassroomUserDto.java
    src/main/java/com/myco/clever/exception/MissingUserException.java

```

I don’t want to commit anything — I just want to get a fresh copy free of any local modifications I’ve done. How do I do this?

Answer: 
You have local changes that you need to "stash" before pulling changes.

One way is:

```
git stash
git pull origin branch-name
git stash pop

```

And now you'll be asked to merge your local changes with the changes you got from server.

Note that you *don't* have to `stash pop` once you `pull`, you can simply leave the stash without the need to merge your previous changes.
If you don't mind losing any changes, you can also `git checkout` the files with changes, but that could take more time depending on the amount of changes you've made, and it won't save the changes for future reference like `git stash` does.