Showing posts with label Git. Show all posts
Showing posts with label Git. Show all posts

Thursday, December 3, 2009

Jarrod Spillers is a Coward

Or has a mental disorder. Or had a really bad day. Or all of it. Anyways, I read his so-so blog post about git merge vs. rebase where a person called Björn makes two good points about the blog post that help not to get confused by what Jarrod didn't get quite right. Instead of saying “thanks, dude”, Jarrod totally dissed him for the “insanely idiotic things” he writes. Yep, I am citing. Couldn't resist to post a comment myself, which elicited yet another comment by a guy called Sitaram, suggesting that Björn is not exactly somebody who doesn't grok git.

Thought I'd revisit the blog a few days later to check whether Jarrod at least got the balls to say “sorry, dude". Turns out he simply deleted his own stupid comment and mine and Sitaram's along with it. Oh, and of course further comments are closed, now.

One reason I love Google's cache:

Anyways, that was really lame, Jarrod. Get some style.

Wednesday, August 6, 2008

Moving on from CVS to Git — cvsps reported error

Don't you just love telling error messages? Like “Error -42”? Or, like yesterday, git-cvsimport: fatal: cvsps reported error Thank you, that'll really help finding a solution. Luckily Mike Schrag got also fucked^Hhit by that error and found that by “simply” launching cvsps on its own first, you can get around that error. There are two things to note here, at least for people who know my humor (they should be scared now): first, why is that so? And, second, why is the “simply” in quotes? I'll leave the first one as an exercise to the eager reader and give you a “try it yourself” for the second one. And no, it's not only RTFM, it's probably UTSL. With Mike's hint I got my last Git post's example working by replacing the single git-cvsimport command by two commands: $ CVSROOT=$(pwd)/ImportRepo cvsps -x --norc -u -A git > /tmp/cvsps.out Then you add another “-P /tmp/cvsps.out” to your git-cvsimport command, like that: $ git cvsimport -A authors-conv.txt -d ImportRepo -C NewGitRepo -P /tmp/cvsps.out git Now it works. At least for me, YMMV. Yeah, seems it's acronym day today, I'm in the mood.

Tuesday, August 5, 2008

Moving on from CVS to Git — How to do the import

Ok, so now Git will be it, what to do? There's git-cvsimport(1), included in git-core. Other people suggest cvs2git(1), especially for complicated histories, i.e. histories with lots of branching and merging. But as branching and merging is a major pain with cvs, I have mostly boringly simple histories, regular release tags and occasional branches being the most complicated stuff. When I organized my CVS repositories when setting them up I majorly messed things up so I want to use the chance to reorganize my repositories and the modules in them. However, git-cvsimport(1)'s man page reads
git-cvsimport [blah] [blah] [cvs_module]
Yeah, that's right, a single module. Googling for hours didn't really reveal anything except trying to rewrite history by using git-filter-branch(1). Being a complete git-noob I decided that's a little too advanced for me. To be honest I hardly understand the man page. kampasky_ on #git gave me the golden clue: simply move the modules you want to intermingle from as many CVS repositories as you like into a common subdirectory (a new ”supermodule” so to speak) and import that. So to transform
CVSRepo1/
    moduleA/
    moduleB/
CVSRepo2/
    moduleN/
into
GitRepo
    moduleA/
    moduleB/
    moduleN/
use the commands
$ cp -pR CVSRepo1 ImportRepo
$ mkdir ImportRepo/git
$ mv ImportRepo/module* ImportRepo/git/
$ cp -pR CVSRepo2/moduleN ImportRepo/git/
$ mkdir NewGitRepo
$ git cvsimport -A authors-conv.txt -d ImportRepo -C NewGitRepo git
If you get the dreaded “git-cvsimport: fatal: cvsps reported error” error message while trying to import be sure to read my next post tomorrow.

Monday, August 4, 2008

Moving on from CVS to Git — Why, and why Git?

For The Great Trip to Canada I decided to convert my CVS repositories to Git. I've always kept repositories on my notebook because I work a lot when I'm on the way. Or when I'm sitting in a café, for that matter. Well, the actual reason is that until recently it was practically unaffordable to be online then. Yeah you lucky bastards living in countries with free WiFi access points everywhere are permitted to feel smug now. I like to commit often so I need to either be online permanently or to have “the” repositories on my machine. With Git (or any other distributed version control system) I don't need to be online permanently and I have repositories on my machine—note the absence of the word “the” here. I chose Git because of several reasons, the strongest one probably being a gut feeling. I watched Linus talk on git, I read tons of pages and posts about CVS, Subversion, Arch, BitKeeper, Mercurial, Bazaar and Git and pages that compared even more. Then I settled on Git. Maybe because I thought that if the kernel people use it (as a replacement for BitKeeper even) it can't be that bad. Maybe because it seemed to have the strongest momentum. Or maybe I just didn't want to be “wrong, stupid and butt-ugly" ;). So it has been decided. More on the technical stuff tomorrow.