checkout

Git error: Your local changes to the following files would be overwritten by checkout

When you get the Git checkout error, “Your local changes to the following files would be overwritten by checkout,” one likely cause is that files in the master branch are indeed newer than the files in your feature branch.

But another possibility that I just learned about is that you did a git add, but forgot to do a git commit before trying to switch branches. My current wrong/accidental workflow looks like this:

How-to: Steps to create a Github pull request

I haven’t worked on many open source projects, so my ability to fork a Github project, pull it down, create a branch, push that branch back, and then submit a pull request are weak, at best.

That being said, I’ve done it a few times lately, so I’m getting better at it. Today was a very smooth process, so I thought I’d make these notes while they’re still fresh in my mind.

Git shortcuts/aliases - How to create

Git shortcuts FAQ: Can I create Git shortcuts (aliases) so I don't have to type out full Git commands like "git commit..."?

I've been reading the Pro Git book a lot lately, and the short answer is yes, you can create Git shortcuts so you don't have to type out the long Git commands. Here are several Git shortcut commands (referred to as "git aliases") from the Pro Git book:

How to use anonymous CVS to access a CVS repository

I can never remember the command-line syntax to access a remote CVS repository via anayonymous CVS access, so just as a reminder to myself, here are the commands I used recently to access an OpenBSD CVS repository:

svn checkout command - how to checkout a project with subversion (svn)

Subversion/SVN checkout FAQ: How do I checkout a project with Subversion?

svn checkout command example

I currently work at a consulting company, so we organize our projects first by client, and then by project. So, assuming I have a customer named ACME, and a project named Project1, this svn checkout command (svn co) worked for me:

cvs checkout - how do I get a snapshot of a CVS repository on a certain date?

CVS checkout FAQ: How do I get a snapshot of a CVS repository back to a certain date?

To solve your first problem, let's assume that yesterday was September 14, 2001, and your project name was KickStart. To check out the code from your KickStart repository from late last night, use this cvs checkout (cvs co) command: