Pushing a Branch Back to a Git Project Repository

Posted by Tres Sat, 18 Oct 2008 03:41:00 GMT

As a former SVN-evangelist, I can say that I came to Git with quite a bit of speculation – wondering why we need just another revision control system. Subversion already did everything we needed – so why mess around with something else.

After using Git for the last few months, I can say that I’m truly won-over. It seems like more-of-the-same at the outset, but as you get deeper into it, it really proves to be one of those really well thought out things you run into every once in a while; I’d liken the move from Subversion to Git something akin to the move from Procedural to Object Oriented Programming. Once you ‘get it,’ there’s really no going back.

Anyway, on to the point of all this.

So you use git push to push a branch you’ve created back up to the project repository.

git push origin DescriptiveBranchName

Posted in  | Tags , , ,

Restore Deleted Files With Git

Posted by Tres Tue, 12 Aug 2008 13:28:00 GMT

This one is pretty easy, but for the fact that the built-in help doesn’t mention git ls-files.

To view deleted files use git ls-files –deleted

To restore deted files just use git checkout – <deleted_file>

Too easy.

Posted in  | Tags , , ,