CONVERTING TO pg ================ pg FOR CVS USERS ---------------- If you've used CVS before here's the rundown of using pg and GIT instead of CVS: CVS COMMAND pg COMMAND ---------------------- ------------------------------------- cvs checkout pg-clone /path/to/.git cvs update pg-rebase cvs add pg-add cvs rm pg-rm rm ;cvs update pg-unedit cvs status pg-status cvs commit pg-ci cvs ci Don't forget that before you `pg-ci` anything you must have a patch applied to accept the change(s). If you don't have such a patch `pg-ci` will error out and ask you to create one with `pg-new`. For the command line oriented: `pg-ci` accepts a -m switch for the log message just like 'cvs ci'. Except `pg-ci` will accept multiple switches and join them together as independent paragraphs of the same commit message. Commit messages entered this way will be automatically line wrapped with `fmt`. You can get help on any command by running with the --help as the only argument: pg-rebase --help You can get a list of pg commands from pg-help: pg-help My typical pg workday looks something like this: ------------------------------------------------ $ pg-new bugNN # start working on bug $ ...hack hack... $ pg-status # see what's changed $ pg-ci -m'blah' # record changes $ ...hack hack... $ pg-ci -m'bleh' # record more changes $ ...test... $ ...oh crap... # realize this isn't going to work (1) $ pg-pop # yank this patch off $ pg-new bugNN-retry # start a new bug fix $ ...hack hack... $ pg-ci -m'better' # record changes ...eat lunch... $ ...test... $ ...hack... $ ...oh crap... # realize bugNN was better $ pg-ci -m'not good' # backup - just in case! $ pg-pop $ pg-push bugNN # oh goodie back to (1) $ ...hack hack... $ pg-ci -m'best' # record final changes ------------------------------------------------ Basically what's happend here is I started developing a fix for bug NN (whatever that is) and I saved a few different revisions of code towards that goal. Typically I `pg-ci` every 10/20 minutes as its fast, cheap, makes it easy for me to see what I've done and also pretty easy to go back if things don't work out as planned. At some point I realized the fix I was working on wasn't quite right (my '...oh crap...' moment). A different approach was needed. So I popped all of my changes off with `pg-pop` which put me back to where I was when I started the day. But the nice thing here is it took <5 seconds to run `pg-pop` and I haven't actually lost any work from this morning (I still have all of it within the patch named `bugNN`). A quick `pg-push` will put it all back for me. So now I create a different patch named 'bugNN-retry' as an effort to start over. I work for a while, test, and change my mind about this `bugNN-retry` method. So I do a quick `pg-ci` to record any outstanding files and `pg-pop` away the bad patch. A quick `pg-push bugNN` and I'm back to where I was before I popped it.