Re: Git BOF notes
From: Petr Baudis <hidden>
Date: 2016-06-15 22:42:34
Hi, Dear diary, on Sat, Jul 22, 2006 at 05:55:59AM CEST, I got a letter where Johannes Schindelin [off-list ref] said that...
On Sat, 22 Jul 2006, Petr Baudis wrote:quoted
Dear diary, on Sat, Jul 22, 2006 at 02:17:48AM CEST, I got a letter where Johannes Schindelin [off-list ref] said that...quoted
Think "changed templates".it may be that I'm just tired, but I don't see what you mean, sorry.If you change a template (like add a hook or something), you can call git-init-db in an existing repository to update that hook.
ah well, I guess that's obscure enough to tell the user to directly run git-init-db. ;-)
quoted
quoted
And also think "setup a remote repository", especially "setup a remote HTTP repository".Of course. Currently you need to tinker with environment variables, then with hooks, possibly with permissions and stuff to make the repository shared... Think cg-admin-setuprepo. ;-)git-init-db --shared
And the environment variable and the chgrp and g+s. That's my point.
quoted
quoted
And also think "start a new repository with only a _part_ of the current files". There are plenty reasons -- in addition to separation of concepts -- not to commit straight after initializing a repository.So what _do_ you do if you don't commit straight?Sometimes, I do "git-push just@initted.repository.com master". From somewhere else, of course.
I guess that's more common for the bare repositories.
And sometimes, I do "cp -R /some/where/CVS ./; git-cvsimport".
git-cvsimport will create the repository for you, won't it?
quoted
Of course sometimes you don't want to add everything, and that should still be possible to do (cg-init has a switch for that).Usually I start small projects as a single .c or .java file. Only after a while, I think it is worth it to init a git database. So, I _always_ have generated files lying around. And I would hate it if they were checked in automatically. (Yeah, I could remove them, _then_ remove them from the index, and then git-commit --amend. Ugly.)
Can't you just do make clean before git init? Or you can prepare .gitignore before you check stuff in, so that the autogenerated files don't pollute your git status output. ;-) -- Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ Snow falling on Perl. White noise covering line noise. Hides all the bugs too. -- J. Putnam