I am currently in the process of teaching some of my coworkers Git. They're all artists, and most of them will probably never need to commit files. However it is valuable for them to be able to pull the latest version of the project and test how things look.
Many of them are running into the issue that they last pulled the project a month ago and tested some things out, but when they need to update the project to the latest master they're hit with a bunch of merge conflicts. I want to give them one simple command that they can run that essentially says "I don't care about any of the changes I made, I just want to go back to master" so that they can then do a git pull without errors.
When I've used git, I generally do:
git add -A
then git stash
However now that I'm teaching git to others, I want to make sure I'm not steering them down a bad path. I've seen other suggestions of using git reset
or git checkout
, but is there a generally accepted best way of saying "I don't care about my changes, blast them out the airlock"?