git and GitHub
Oct. 17th, 2009 02:30 pmI'm finally working with Git (thanks to
hostilefork and folks on the IRC #git channel). I like the separation between 'commit' and 'push'. In the past, I've worked with CVS and SVN, which apparently don't make that distinction.
'commit' creates a checkpoint in your local machine, to which you can go back (and apparently tracks diffs). 'push' updates the server with the last committed version.
I've been using GitHub as my backup service, which means that I've been committing and pushing "dirty" code (unreadable, untested, etc)... which may become a problem. Will Git let me tag some versions as official?
'commit' creates a checkpoint in your local machine, to which you can go back (and apparently tracks diffs). 'push' updates the server with the last committed version.
I've been using GitHub as my backup service, which means that I've been committing and pushing "dirty" code (unreadable, untested, etc)... which may become a problem. Will Git let me tag some versions as official?
(no subject)
Date: 2009-10-17 10:41 pm (UTC)(no subject)
Date: 2009-10-17 11:28 pm (UTC)(no subject)
Date: 2009-10-17 11:29 pm (UTC)(no subject)
Date: 2009-10-17 11:35 pm (UTC)I haven't done very much yet, but it's been working ok.
(no subject)
Date: 2009-10-17 11:39 pm (UTC)Btw, is 'branch' a local operation? Can you push things to the server, even if there's no new commit?
(no subject)
Date: 2009-10-17 11:47 pm (UTC)I'm sure you can push branches to a server.
(no subject)
Date: 2009-10-17 11:56 pm (UTC)So your topology would look like this?
o---o---o---o---o---o---o---o---o---o---o \ \ \ o o o(no subject)
Date: 2009-10-18 02:03 am (UTC)Branching is a local operation, and you can push that to the server even if there's no commit. (You're just pushing the pointer.) Of course you'll have to figure out the magical git syntax to do that. I wrote a script called `git publish-branch` that you can search for.