OT: Git help


#1

I never feel confident with what I’m doing with git. I just always feel like I’m about to do something stupid and catastrophic. Please bare with the lame question…

My local copy of JUCE is from the develop branch, about 40 commits behind and I just want to catch up.

If I do a git pull, it says that I’ve got unsaved changed (typically from compiling and running Plugin Host or similar). I don’t care about those changes, I just want to get the latest from develop and overwrite my changes.

What’s the proper thing to do here? Something I’m sure you all do every so often…or am I missing a better way to with with JUCE and git?

Thank you.


#2

git stash
git pull


#3

That was too easy.

Thank you.


#4

I use Source Tree to do that if you need a GIT front end. It tells you you need to Stash your changes.

Rail


#5

And from my knowledge of git (correct me someone if I’m wrong), if you want to keep your changes you can continue with “git stash pop” and an attempt to merge your changes with new the juce version will be made. Which may or may not succed depending on your changes.