IRCloggy #git 2007-09-29

Logs Search ←Prev date Next date→ Channels Documentation

Provider of IRC logs since 2005.
WARNING: As Freenode became unjoinable and lost all warnings in topics, we cannot log channels on Freenode anymore.

2007-09-29

MadCoder heh ohloh is using a webserver I had never heard of before00:00
funny00:01
gitte gitster: now it worked, oddly enough...00:01
gitster nice ;-)00:02
heh, I wonder what would happen to that Kudo I gave to the two people that are merged into one ;-)00:03
Mikachu i would guess they only keep one of them00:03
gitte Actually, I have but rank "1" now.00:04
gitster Mikachu: I'd hope so.00:04
Don't worry, they will recompute once a day.00:04
ferdy left00:04
Mikachu phew00:04
gitster Looking at other project's contributor stats is always interesting.00:04
gitte 20,134 lines changed.00:05
Hehe.00:05
gitster You can tell whom to hit with a bus to kill your competitor ;-)00:05
gitte gitster: you don't have any...00:05
competitors.00:05
MadCoder gitte: that won't last00:06
gitster more seriously, we are a lot flatter than others.00:06
MadCoder I'm at rank 9, and I'm not a very big contributor in any very famous project yet00:06
maybe except debian00:06
though sth unfair is that the svn guy is 4th :P00:06
gitster I do not think that rank number means anything.00:07
gitte normalperson worked quite hard for that rank, though.00:07
branstrom left00:07
gitte (But he's 5th AFAICT)00:07
MadCoder by 4th I mean he's at rank 10, 4th in the general list00:07
and "the svn guy' is svn upstream00:08
not git-svn00:08
gitster is only 70 or sth00:08
gitster ohloh is owned by svn company so it is not very surprising ;-)00:08
MadCoder haha00:08
really ?00:08
gitte Karl Fogel also wrote CVS, and parts of Emacs.00:08
MadCoder well, I a fan of none of the three00:09
pasky hmm, ohloh00:09
MadCoder used svn a lot, barely CVS (too young) and never emacs :)00:09
pasky is that another advogato rehash?00:09
gitte I used CVS a lot, and was utterly disappointed by svn.00:09
It took me 3 days to create my first svn repository.00:10
gitster http://www.collab.net/news/press/2007/ohloh.html00:10
MadCoder gitte: well, I spent some time using tla00:10
it took me 3 day to remember how to commit00:11
:)00:11
gitster did too. it was very steep.00:11
MadCoder *days damnit00:11
gitte Git is the 61st in the project list.00:11
MadCoder (and I've all forgotten since)00:11
gitte But CVS is 51st.00:12
gitster and I recall it was not usable without setting up revision library which was not done by default, just like git is unusable without initial repacking. So in that sense I do understand the worry Linus had about unpacked repositories.00:12
gitte And Spring is in more stacks than Git. That POC!00:12
MadCoder spring ? what isit ?00:12
gitster you are joking, right?00:13
gitte MadCoder: you don't want to know.00:13
spearce that hasn't sprung into the junk pile yet?00:13
gitte About Spring being in more stacks? Nope: http://www.ohloh.net/projects?page=3&sort=stack_count_reverse00:13
I actually personally know a few people who love Spring.00:13
spearce we only have 3 more to pass it00:13
MadCoder oooh java00:14
gitster allergic to caffeine?00:14
gitte It's also an island, you know?00:14
gitster and people from there are javanese. how confusing ;-).00:15
MadCoder gitster: have you by any chance had some time too look at my proposal to avoid the NULL ->buf pitfal ?00:15
damn, I've received kudos from people I've absolutely no clue who they are00:15
gitster Looked good on the initial pass but haven't had chance to look at any patches deeply enough for the past 24 hours.00:16
MadCoder np00:16
I was afraid the strbuf_slopbuf was freaking you out :)00:16
gitte MadCoder: you check for that when realloc()ing, right?00:17
MadCoder yes00:17
gitte (of course you do.)00:17
MadCoder it's even detailed in the commit message00:17
gitte Which I did not have the chance to read in detail.00:17
gitte was too busy the last few days00:17
MadCoder I wasn't blaming you00:17
my commits messages tends to be too long nowadays00:19
gitte No, they are just right.00:19
MadCoder (and my english worse when it's that late)00:19
gitte Not as bad as in "a dyslexic man walks into a bra..."00:19
MadCoder anyways, as nobody was responding, I was afraid the static slop buf was of too bad taste00:19
pasky hmm00:20
looks like ohloh can't be used w/o javascript?00:20
gitte pasky: hmm back00:20
pasky or something?00:20
gitte AJAX.00:20
pasky at least stack can't00:20
bah00:20
GyrosGeier left00:20
pasky they should write that somewhere so that I don't waste my time :)00:20
MadCoder but that's the most straightforward and lightweight mechanism I've thought of00:20
spearce pasky: its web 2.0. you need a "real" browser. :)00:20
gitster Is anybody interested in seeing "interactive unstash"?00:23
gitte How's that look like?00:23
MadCoder and what would it do ?00:23
gitster You have a huge change that is complete in your work tree and you would want to split.00:24
You stash it away, and then trickle bits in from it and commit after testing in the work tree.00:24
gitte Ah, and you get it piece by piece...00:24
That's a nice idea.00:24
gitster Rince repeat continue until the stash gets empty.00:24
gitte But actually, I'd try to enhance git gui to do that...00:25
gitte is trying to find the time to clean up that splitting hunks patch.00:25
gitster if it were perl/Tk instead of tcl/Tk you could have talked me into it...00:26
As I've already done the same thing twice already. Once originally for jit and then for add--interactive.00:26
MadCoder hmm I see00:27
wasn't git add -i supposed to do that ?00:27
gitte MadCoder: not really: git add -i is about index <-> worktree interaction00:27
This would be about stash <-> worktree interaction00:28
gitster interactive unstash is going the other way.00:28
MadCoder hmmm00:28
gitster "add -i" is a wrong workflow. What you commit is not something you had in the work tree as a consistent whole.00:28
gitte But it would be similar enough that it's probably just an enhancement of git-add--interactive.perl, right?00:28
gitster Probably.00:28
MadCoder I'm not sure I would have a use for it, when I split a patch for commits, I use my $EDITOR because I've not found anything else I'm really confided with yet00:28
gitster But more like "git stash apply -i" ;-)00:28
MadCoder oh, seen like this it may be interesting00:29
like we discussed some days ago, my workflow is currently:00:29
split patch, git add and commit00:29
git stash00:29
test it builds and whatever else00:29
git stash apply00:29
got back to the splitting part00:29
gitte I have basically two different work flows:00:30
mnemoc left00:30
MadCoder but a git stash apply -i makes sense00:30
I thought you were proposing git stash -i00:30
and that didn't made real sense to me00:30
actually git stsah apply -i may be a brilliant idea00:30
gitte One (rarer) is to split commits as described in SPLITTING COMMITS in git-rebase.txt00:30
And the other is: commit really often, with short descriptive onelines.00:31
Then to clean up the patch series, rebase -i and squash quite a lot.00:31
Mikachu so you never commit and leave them? :)00:32
gitte To test, I rebase -i, and mark all (except the last one) "edit".00:32
Umm. No.00:32
MadCoder gitte: yeah I try to have this workflow nowadays00:32
gitte I commit _really_ often.00:32
MadCoder (the commit often and then rebase -i to cleanse history)00:32
though sometimes I'm in the middle of a big refactor, and from thread to the needle (not sure it's the proper expression) I endup with a patch touching 1k lines :)00:33
and here git stash; git stash apply -i may be really nice00:35
"okay, let's pretend we redo that ... sloooowly"00:35
fonseca <shameless plug> recent tig supports staging of chunks </>00:37
gitte But without being able to split hunks, I think it will not be as useful for me sa with it...00:37
gitster fonseca: yeah, I learned about it last night ;-)00:38
gitte fonseca: I actually like tig very much...00:38
orospakr joined00:38
fonseca Cool :)00:38
MadCoder likes the idea of tig very much00:40
MadCoder but I'm just unable to use it00:40
brain issue00:40
REPLeffect_ I have a question about GIT_DIR, and GIT_WORK_TREE.00:43
fonseca Heh, that is a new one.00:43
REPLeffect_ If I set GIT_DIR AND GIT_WORK_TREE to directories in different heirarchies ...00:43
should I be able to execute commands from anywhere inside the work tree ...00:44
gitte Yes.00:44
REPLeffect_ and have them correctly discern where I am relative to the root of the work tree?00:44
gitte Yes.00:44
REPLeffect_ it doesn't seem to work with 1.5.300:44
commands at the root work fine.00:44
gitte sgrimm: ping!00:47
spearce left00:54
REPLeffect_ unless For instance. I have a work tree in /wt ...00:56
gitte MadCoder: Linus has a good point here, no?00:56
REPLeffect_: lemme check00:56
sbohrer joined00:56
REPLeffect_ OK00:57
(the "unless" in that statement was unintentional)00:57
gitte Yes, I can reproduce.00:58
REPLeffect_ What command did you try?00:58
gitte git diff00:59
REPLeffect_ adds with relative paths don't seem to work either.00:59
neither do commits of adds that I do from the root.00:59
git status will show an added file, but with a path starting at the root.00:59
Hm. I guess git status *always* shows you the file from the root (even if you are in a relative dir)01:03
gitte I think we borked your use case...01:03
REPLeffect_ hehe.01:03
stuff happens.01:04
gitte (Meaning _I_ borked it)01:04
REPLeffect_ Well, I spent a fair amount of time trying to get my head into the code.01:04
and, well, I think I didn't succeed very well.01:04
or I guess I should just say I *didn't* succeed.01:05
I know the GIT_WORK_TREE stuff is fairly new. So I would expect there to be a few kinks to work out.01:07
jasam left01:10
REPLeffect_REPLeffect01:15
spearce joined01:21
gitte REPLeffect: I'm somewhat lost... There might be something I missed why the code behaves as it behaves; and I'm too tired to think about that right now. Will attempt a fix tomorrow, okay?01:25
REPLeffect hey, that would be awesome.01:26
I'll be happy to play the guinea pig if you want some help testing.01:28
gitte Bed time! Git night!01:29
REPLeffect git night, sleep well.01:29
gitte left01:29
REPLeffect left01:30
herzi left01:31
engla left01:39
tcoppi|laptop joined01:40
GyrosGeier joined02:02
bicchi joined02:07
bicchi I was thinking that git-config should have an option to set the commit editor. like: git config --global user.editor "gedit"02:08
Mikachu wouldn't that be core.editor ?02:09
bicchi is there such an option already?02:09
Mikachu quite02:09
"Commands such as commit and tag that lets you edit messages by launching an editor uses the value of this variable when it is set"02:10
bicchi ok them. core it is02:10
Mikachu you can also set the env vars VISUAL, EDITOR or GIT_EDITOR02:10
diactitical joined02:11
bicchi i guess it would be nice if it integrates with the git-config command02:11
cods left02:12
glguy joined02:13
a2c joined02:14
gitster Huh? "GIT_EDITOR=vi git config" starts your favorite editor and lets you edit your configuration file?02:16
glguy left02:20
glguy joined02:22
topfunky left02:24
glguy left02:29
aroben_ joined02:34
aroben_ left02:36
aroben_ joined02:36
aroben left02:37
aroben_ left02:38
aroben joined02:39
rtmfd_ joined02:46
GyrosGeier left02:48
GyrosGeier joined02:48
fowlduck joined02:51
bicchi left02:57
rtmfd_icbm left03:02
elmex_ joined03:05
rtmfd_icbm joined03:14
rtmfd_ left03:14
rtmfd_icbm left03:14
rtmfd_icbm joined03:15
elmex left03:20
a2c left03:22
GyrosGeier left03:22
fhobia joined03:28
tcoppi left03:32
tcoppi joined03:34
kanru left03:39
madewokherd` left03:42
diactitical with git remote add is if you dont get it right the first time, you have to edit the config file right?03:42
not that the following question makes sense: but to achieve the equivalent of the INSTALL instructions to fetch man and html, you would use git add --remote03:44
erm03:44
you would use `git add remote --mirror' right ?03:44
i'm trying git init; `git add remote [-t master] --mirror ~/path/to/repo' but that just fails03:51
however i get what i want by doing (a=`pwd`; cd ~/path/to-repo; git push $a master:refs/heads/master)03:56
i think there may be some benefit from simplification of syntax --- like rsync dtrt with src and dest and it figures out whether to do a push or a pull.03:58
not pull: i meant have --fetch/ --pull as an argument03:59
rtmfd_icbm left04:00
diactitical current intelligence notwithstanding, i cant find any unifying principle which simplifies or facilitates my understanding in the current scheme04:00
fhobia left04:01
Sho_ left04:07
aroben left04:07
orospakr left04:09
orospakr joined04:13
diactitical after my last command, if i do (cd $a; git checkout -b newbranch; echo changed >> file; git commit; git push ~/path/to-repo newbranch:newbranch) --- there is a huge performance problem04:16
it takes minutes to complete04:17
the refspec is actually newbranch:refs/heads/newbranch04:17
the size of the .git is under 500k04:17
it cant just be because of nfs could it04:19
this behaviour i'm seeing is on git-maint04:20
gitwump git's performance is sometimes quite dependent on a good buffercache04:20
(sometimes meaning, for certain operations)04:20
diactitical my whole source tree is under 200k04:21
< 50 commits04:21
gitwump which part is slow?04:24
diactitical git push where i'm creating a new branch on the remote04:24
it says: Total 34 (delta 14), reused 33 (delta 14)04:25
then Unpacking 34 objects...04:25
this takes minutes04:25
rkaway left04:27
spearce oh, unpacking is decompressing the objects back to disk04:27
diactitical I did do git gc --aggressive --prune on both ends before the operatin04:28
that would explain it?04:28
spearce sounds like its just taking a long time to write the objects to disk04:28
diactitical ok (but still a hmm, i'm doing bzips of huge files fast enough)04:29
rkaway joined04:29
diactitical had no luck with git --mirror on git-maint04:31
diactitical spearce, maybe its just NFS issues. i'll take back that user experience for now04:34
spearce oooh, NFS? yea. i've seen unpacking loose objects *suck* on at least one freebsd NFS installation. i don't blame freebsd, i blame an overloaded server that was too busy to keep up with its clients. :-)04:34
drop your transfer.unpackLimit to a really low number. its default is 100. it can help by only making the .pack and .idx instead of lots of loose objects.04:35
diactitical will try that next time!04:36
off04:37
diactitical left04:37
glguy joined04:38
sbohrer left04:43
mgrimes joined04:45
tcoppi left04:56
tcoppi joined04:57
radarsat1 joined04:59
radarsat1 hello, i have a quick question about git if anyone can help05:00
i'm exploring the idea of moving my project to git which is currently under svn05:00
the project is organized such that there is a main codebase, and a library05:00
i think it might be best to keep these as separate "projects", i.e., each in its own repo05:01
spearce probably, especially if the library's development history and release schedule is different from that of the main codebase.05:01
radarsat1 but what is the best way to inform git of their dependency? i looked around a bit but couldn't find a faq on this05:01
spearce use the new git-submodule supported in 1.5.3 (and still being improved in latest versions from git.git)05:02
radarsat1 in svn, i am used to just treating each subfolder as a separate subrepository, so i just use one big huge repository for everything, and i don't have to worry about this05:02
ah, thanks i haven't read about that05:02
sounds like that's about what i'm looking for: "Add the given repository as a submodule at the given path to the changeset to be committed next.05:03
thanks!05:03
ah, sadly it looks like Ubuntu's not up to that version. *sigh* well i guess i can just compile it myself..05:04
cheers :)05:04
spearce yea, its pretty easy to get git with git.05:04
radarsat1 thanks again, i'll pop in again if i have another question.. :) thought it might be faster than bugging the mailing list05:05
radarsat1 left05:05
udi_trugman joined05:19
Pistahh left05:25
tcoppi|laptop left05:28
tcoppi left05:28
tcoppi joined05:33
spearce left05:34
DrNick left05:59
topspin joined06:47
krawek left06:47
Evelynn joined06:48
glguy left07:01
Evelynn left07:09
dduncan left07:27
topspin left07:45
MadCoder heh linus subscribed to ohloh07:51
gitster can't believe it.07:54
MadCoder well, someone did for him then :]07:55
I just went to see if gitte was ranked already, and I saw that linus has merged his linux and git contributions07:56
that'll be fun to see him jump in the top 10 directly ;)07:56
gitster Yeah, he used to be two separate entries, the kernel one being somewhere around 70-80 range.07:57
I guess he learned about it by reading the #git channel log ;-)07:59
MadCoder heh07:59
he is _that_ bored to read channel logs ?07:59
gitster 35 more to go ;-)07:59
MadCoder btw that's the sucky part of ohloh, not being able to join identities of people not subscribed but who you know are the same person08:00
gitster keeping an irc client open risking getting distracted is way far less efficient; skimming the channel log every three days is a lot more efficient way to stay up to date.08:00
MadCoder heh right08:00
gitster Yeah, I've discussed with ohloh people in their "forum" about it a few times.08:01
The easy thing they could do is,08:01
Just register a fake user themselves, have _him_ claim "I am this person" to consolidate the entries.08:01
MadCoder and unregister him ?08:02
gitster Because they _must_ have an identity dispute procedure already established,08:02
MadCoder well I would be surprised you would need such perverts ways to achieve that08:02
probably08:02
gitster just in case if I claim to be you by mistake.08:02
So they do not even have to unregister that fake person. They can just wait until the real one comes and disputes.08:02
MadCoder that's an option08:03
gitster Then they can transfer the identities to the real owner and retire the fake one.08:03
cods joined08:04
gitster Yay, we are at 165 tied with gitte's unfavorite language ;-)08:04
MadCoder heh08:06
drizzd left08:08
Ilari What language is that?08:09
MadCoder it's not a language but some kind of library or toolkit or sth similar08:09
for a language that smells coffee08:09
gitster There are a handful entries at 165 stacks last time I checked a few minutes ago.08:10
MadCoder: Bzzt.08:10
It is my understanding that gitte does not have much against that language. What he dislikes is a Japanese one, not Javanese one.08:11
heh, they recomputed and Linus is at rank 43 now.08:12
MadCoder oh it's a ruby thing ? I thought it was for java08:14
"only" 43 ?08:16
heh08:16
gitster: heh, welcome in the elite ;)08:17
gitster well, I am a bit unhappy that this moved linus a bit above my second mentor X-<.08:18
but that's fine because linus is my third mentor anyway ;-)08:19
MadCoder the two previous being ?08:19
the tar guy and ?08:19
xiaoxiaoqing joined08:21
xiaoxiaoqing left08:22
eMBee good evening08:24
gitster good whatevertime.08:24
MadCoder: don't worry, my first mentor predates this whole open source craze and nobody would know him.08:25
MadCoder heh08:25
so you're a dinosaur then08:25
gitster depends on how old I was when I was trained by him ;-)08:26
eMBee computer related training? or martial arts or something?08:27
MadCoder haha08:27
gitster joy of hacking.08:27
up_the_irons left08:28
eMBee hmm, i think you can teach the joy of hacking to a 5 year old, so yeah, that doesn't make you old08:31
up_the_irons joined08:32
roundeye joined08:38
roundeye odeley cholos08:38
im looking for some good docs on encryption08:38
MadCoder and what make you think #git is the place to ask for it ?08:40
roundeye why not08:40
go tr0ll some one else08:40
are you saying that the people in git are nubs?08:40
gitster MadCoder: two questions.08:49
blokkie how do I name my project and branch ? now it's like this : http://first.h0m3.be/pipermail/svn-grudge/2007-September/000191.html08:52
gitster this is quite up to the person who set up the hook script in the repository.08:53
blokkie I am08:54
roundeye left08:54
gitster Are you using the Andy Parkins script from contrib?08:54
blokkie so I need to adjust the config on my git server ?08:54
yes08:54
my config does not contain [branch]08:54
gitster It seems "UNNAMED PROJECT" is taken from ".git/description" (or lack thereof).08:55
I am not following your question about "branch". I think the mail look funny because it talks about "UNNAMED PROJECT" but otherwise I do not see anything funny about it.08:56
It would say something like "Blokkie's Cool Gadget branch master updated."08:56
when the branch 'master' was updated.08:56
blokkie ah ok , I adjusted the description , cool08:57
now about [branch]08:57
I don't have any such thing08:57
in my config08:57
gitster That has a good side effect of showing that name in the gitweb.08:57
blokkie onlt core and hooks08:57
metafollic left08:57
gitster What makes you say you need [branch]?08:57
up_the_irons left09:00
garry joined09:01
MadCoder gitster: yes ?09:01
garryup_the_irons09:02
gitster (1) what's the rationale behind slop[32]? Not slop[4] nor slop[1] nor slop[100]?09:02
MadCoder oh, in fact I think 8 should be enough09:02
it's to be sure that if we read a intmax_t it fits09:02
gitster (2) without strbuf_init() assigning slop[0] = '\0', does it still guarantee that "people can always assume buf is non NULL and ->buf[0] is '\0'"?09:03
MadCoder I don't understand (2)09:03
I mean I don't get what you are asking09:04
gitster The comment says slop is to guarantee that people can safely assume buf.buf != NULL and ->buf[0] is '\0'. I do not understand the latter guarantee.09:05
MadCoder the slop is full of zeroes right ?09:05
and after init everyone shares the same09:05
metafollic joined09:06
MadCoder in fact what I mean is that with this thing, after initialization, the "empty" strbuf is not special cased anymore09:06
gitster After init everybody shares the same and, ah, after init ->len is 0 so nobody is supposed to write into there without first _grow() which would allocate the real thing.09:06
MadCoder ->buf holds a NUL terminated buffer even with alloc == 009:06
exactly09:06
gitster ok, I see.09:06
thiago_home shared_empty09:06
MadCoder though there may be people that would do a ->buf[0] = '\0' and this still works09:07
gitster Then that makes me confused about your first answer.09:07
MadCoder (people doing that would be wrong but ...)09:07
gitster rtrim does that.09:07
thiago_home I would say that you cannot access buf[0] if len == 009:07
MadCoder thiago_home: you can access buf[len] in a strbuf09:08
and it's always \009:08
that's the whole point of strbuf's09:08
thiago_home hmm... ok09:08
thiago_home is too used to Qt09:08
thiago_home you can't access str[str.length()]09:08
MadCoder gitster: well maybe my first answer is stupid09:08
maybe a 1 char buffer is enough09:08
gitster I do not mind wasting 31 bytes but I want a good rationale behind any magic numbers.09:09
MadCoder well, that sounded clever at the time09:09
and now I do not see how to justify it09:09
so it's probably dumb09:09
8 would preserve good alignement though09:10
gitster Ok, let's shrink it to 1 and see what breaks ;-)09:10
MadCoder but I suppose the C compiler already does that09:10
gitster That's a good rationale.09:10
thiago_home char[n] has an alignment of 109:10
gitster yes.09:10
MadCoder thiago_home: I meant the address of the array09:10
thiago_home you can't do that with a char array09:11
MadCoder anyway we're not supposed to read more than 1 byte in it09:11
gitster I do not think you nor compiler need to align char[].09:11
thiago_home if you want to force the alignment, you need to have a field with a higher alignment constraint09:11
MadCoder so alignment hardly matters anyway09:11
thiago_home yep. Why force it?09:11
gitster let's make it slopbuf[1] and see what breaks ;-)09:11
MadCoder gitster: so well, char[1] may be totally okay09:11
gitster I do not think there should be none.09:12
mmagnon joined09:12
MadCoder in fact s/may/will/09:12
gitster s/do not//;09:12
mgrimes left09:20
gittish someone updated some example scripts and added error checks to open for pipes, i.e. open X,"git .|" || die, but didn't add the test at the more likely place to see and error, ie. at close()09:35
tko left09:36
kumbayo joined09:37
gitster typical mistake.09:37
kanru joined09:37
zecke joined09:40
alley_cat joined09:41
tko joined09:45
udi_trugman no09:48
engla joined09:55
gittish no?09:55
cortilap joined10:01
drizzd joined10:02
alley_cat left10:09
alley_cat joined10:10
CIA-11 left10:15
G0SUB left10:20
zecke left10:26
Lash| joined10:28
CIA-11 joined10:29
Lash| left10:33
zecke joined10:37
kumbayo left10:40
engla git rev-parse --branches prints the shas to all branch heads10:41
when I do git rev-parse --short --branches it writes them all out in short form and _then_ exits with "fatal: Needed a single revision"10:42
nud_ joined10:42
Auris- kinda like cryptsetup which complains and segfaults when run as non-root.10:44
zecke left10:55
eMBee left11:01
nud_ cworth: great introduction to git in your latest blogpost11:03
cworth: anyway, there is a little typo in there, in 2.7.1: "If any of the GITAUTHORNAME, GITAUTHOREMAIL, GITCOMMITTERNAME, or GITCOMMITEREMAIL..." <-- those are missing the underscores11:03
eMBee joined11:08
CIA-11 left11:08
Lash| joined11:08
branstrom joined11:12
CIA-11 joined11:12
eMBee can i use the oprions to git-diff with git-cherry?11:14
options11:14
MadCoder no11:19
git-cherry cannot take more than 4 arguments11:20
though you can probably pipe the output to git-rev-list --stdin with appropriate options11:22
which would not help silly me11:22
git-diff-tree --stdin rather11:22
eMBee well, i want to influence the revisions that git-cherry produces11:23
MadCoder oh11:23
well no git-cherry doesn't do that11:23
though it would definitely make sense11:24
eMBee or rather, i want to compare two trees, but only find differences that are not caused by missing files in one tree11:24
MadCoder ask for the feature on the list ? :)11:24
eMBee is not on the list yet, should make a note of that11:25
eMBee any workaround suggestion?11:26
MadCoder well, I'm in need for substantial food, and it deprives me from my neurons efficiency (which isn't that high usually, so imagine right now)11:26
eMBee: if there is a way to tell git log / rev-list/... I want all the patches that touches at least one other file than "your file"11:27
then you can make the intersection of the one git chery gives and those11:28
I'm not sure if git log/rev-list have this kind of expressivity though11:28
(or you can list every file in the repository except these)11:28
eMBee hmm, i don't know what the file would be though11:29
i could approach this from a different angle and look at the time the change was commited11:30
in this case i know that the commits happened at the same time11:30
(background is that i am comparing two cvs trees, one of which has files missing)11:30
as a result ALL commits in the trees will be different, but i want only those commits which are different by more than the missing files11:32
Lash| left11:37
branstrom left11:39
zecke joined11:46
Lash| joined11:47
branstrom joined11:49
gittish create two branches, one for each tree, delete the to-be-ignored subtrees and compare11:51
not very practical if you want to compare over and over with different trees11:52
eMBee i don't want to compare trees but commits11:52
erm11:53
there seems to be tweo uses for the term tree here11:53
i am talking about the commit/branch tree not the file/directory tree11:53
one branch has A--B--C--D and another A'--B'--D' where A and A' differ only by some files, now i want to find that C which has no equivalent C'11:55
janm left11:55
eMBee right now i am attemting a brute-force comparison of the commit timestamps, because i know they are identical for A and A' ...11:56
nud_ left11:58
eMBee does git-rev-log --all give me all commits in the whole repo?12:01
vmiklos git-rev-log?12:02
Oejet joined12:03
Evelynn joined12:03
eMBee erm git-rev-list12:05
zecke left12:05
Sho_ joined12:05
eMBee sorry, got mixed up, was looking at git-log which made me look at git-rev-list for options, got them merged in my mind into git-rev-log :-)12:06
mneisen joined12:06
vmiklos git-rev-list (by default) will only list commits from the current branch i think. so no, it won't list all commits12:07
eMBee which is why i am asking about the --all option12:07
the manpage describes it as: Pretend as if all the refs in $GIT_DIR/refs/ are listed on the command line as <commit>.12:08
vmiklos ah, my bad12:08
then yes, it seems so12:08
eMBee that seems to be enough to make it list all commits, but i am not sure if it really means that12:08
janm joined12:13
chris2 joined12:14
nud joined12:14
Yuuhi joined12:23
zecke joined12:23
fowlduck left12:27
madewokherd joined12:29
Beket_ joined12:39
zecke_ joined12:39
zecke left12:51
kristoffer joined12:54
FunkeeMonk joined12:57
zecke joined12:57
gittish eMBee: a commit implies exactly one tree. so when comparing two tress, you are actually comparing two trees.12:58
(update) eMBee: a commit implies exactly one tree. so when comparing two commits, you are actually comparing two trees.12:58
the only difference is that a tree can refer to any tree, but a commit implies the top level only12:59
eMBee right, my point was that i am not so much interested in the state of the tree but in the changes the commit introduces13:02
gittish still the same thing13:03
bentob0x joined13:04
eMBee not quite: two commits can be different but the changes they introduce could be the same13:04
gittish man git-cherry13:05
could that be something for you?13:05
eMBee no, already been there, problem is i need to find a specific set of differences (ignoring missing files in one tree)13:07
gittish is that your *real* problem or a hypotetical partial solution to your problem?13:08
zecke_ left13:09
gittish what you are asking for in not available in the current version of git13:09
eMBee my real problem is that i have 7 branches of a cvs repository, where the branches have been created by copying the whole repository. the branches represent the stable releases. i pulled all those into git, and now i want to create a merged repo that shows branches at the actual branchpoint. problm is in the newer branches files have been deleted from the repo (maybe they forgot to copy the attic or something) so on importint into git the commits wil13:11
Beket_ left13:11
eMBee now what i am trying to find out is if missing files is the ONLY thing where the repos differ, or if there are other differences as well (and there are)13:11
gittish i mentioned something above that doesn't scale well, but for seven branches it is quite feasible13:13
seven branches and a one-time event13:13
eMBee well, i pretty much need to compare all the commits13:14
gittish filter-branch then13:14
replicates your branches commit by commit removing stuff13:14
eMBee hmm13:15
that could be interesting13:15
CIA-11 left13:15
eMBee although i'd rather add stuff, but that should work too13:15
FunkeeMonk left13:16
gittish that would be harder13:16
eMBee you are right13:16
but that's what i need to do in the end13:17
hmm13:17
this will take more thinking13:18
there are more than 10 years of history13:18
gittish hmm, you won't even have the ability to do commit-by-commit compare, I think13:19
those copied repoes reflect the true history of those branches. They *did* delete files.13:20
eMBee yes, well, the trouble is deleting the files resulted in deleting the history of those files13:21
gittish that would be a a problem if you want to merge13:22
(or well compare)13:22
eMBee that is the problem indeed13:22
which i am trying to solve13:22
gittish otoh, what happens if you do?13:23
eMBee compare? well all commits are different, rather hopeless without more intelligent heuristics13:23
gittish so do you need to compare commit by commit, or will the tips solve your problem in practice13:24
eMBee i am not sure yet13:25
gittish another version is to rebase those copies onto a version that has all files to begin with13:25
eMBee yes, hmm13:26
indeed, that might do something13:26
gittish i doubt you'll see a clean solution, but hopefully one that doesn't suck very much13:26
eMBee but the rebase would only give me the initial file not it's history13:27
its13:27
gittish the copied branch didn't change it, so there is no further history on *that* branch13:27
eMBee well, i do know where the branch points are pretty much, and i did create a merged tree by importing from cvs onto the branchpoint, however i found that some commits got lost somewhere in the process13:28
gittish you want a "git knit" command13:28
eMBee :-)13:28
CIA-11 joined13:29
eMBee the copied branch deleted the file and its history, so if i rebase i need to rebase at the branchpoint, not rebase the while branch, i did that13:30
now i need to find those lost commits, which requires looking at the original repos13:30
_saserr_ joined13:30
engla the discussion is above my head, but you are going to rewrite the history to put in the missing history in all branches? terrific13:31
_saserr_ left13:33
asdx joined13:34
eMBee maybe an example can help: consider A--B--C--D--E--F and A'--B'--C'--E'--G, two histories, created by copying at the point of E. now i am trying to create a merged history that has A--B--C--D--E<(branch here into F and G)13:34
nikodemus joined13:34
nud left13:34
eMBee but notice how those histories have D' missing13:34
nikodemus left13:34
eMBee commits like that i am trying to find13:35
nud joined13:35
gittish I think I understand, but I'm not convinced it is worth it. Interesting problem though.13:35
eMBee well, the critical issue is that some of those commits are remove of files13:36
in the head of the newst branch i have files that should have been deleted years ago13:36
i need to find where they have been deleted and add that delete commit into the history13:37
other irregularities are not so critical, but this part is, as at least the heads of all branches need to be correct13:38
gittish hmm, git-merge -i and give it all your commits in those branches13:38
rebase -i13:38
eMBee yes, after i found where the files need to be deleted13:38
im still at the stage of figuring out how to find that13:39
once i found them, branch, delete and rebase are clear steps13:39
gittish rebase -i will cherry pick, but skip if a commit effectively introduces no change because it has already been applied13:40
sbohrer joined13:40
gittish but it won't tell you how many times it will stop beforehand13:41
eMBee the whole repo has about 26000 different commit timestamps13:42
gittish good luck....13:43
eMBee hehe13:43
hmm 2900013:44
gittish i'd skip fixing the history and just fix the tips. Even if you think you fixed it, can you really verify that what you did is correct?13:44
eMBee well, i believe finding out when those files have been deleted should not be to hard13:45
and give a reasonableapproximation13:45
to find what i did is correcti i can check out at each release (which is tagged), and compare with the actual release, or a checkout from cvs13:46
should be able to script that13:46
i want to do this in preparation of getting the project to switch to git, the better the job the more chance i have of convincing them it is a good idea13:47
well, thanks for the support so far. it is 2am here (and we got daylight savings coming up tonight, so it's actually 3) time to go to sleep13:49
G_SabinoMullane joined13:50
Lash| left13:51
CIA-11 left14:05
krawek joined14:11
bentob0x left14:12
CIA-11 joined14:19
_ry joined14:33
_ry left14:35
kumbayo joined14:39
rtmfd_icbm joined14:40
agoode left14:51
bdiego joined14:58
nud left15:03
nud joined15:08
mmass0nnet joined15:08
segher_ left15:10
m8t left15:11
mmass0nnetm8t15:11
branstrom left15:12
branstrom joined15:19
cdcarter joined15:20
cdcarter left15:22
alley_cat left15:35
alley_cat joined15:36
drizzd left15:37
drizzd joined15:37
CIA-11 left15:39
nessundorma joined15:45
robfitz_ joined15:45
mithraic joined15:46
madduck http://blog.madduck.net/vcs/2007.09.29_uninformed-slagger15:46
thank you, git people...15:47
you made writing this post a joy!15:47
radiomark joined15:52
mithraic left15:53
mithraic joined15:54
mithraic So I'm thinking of migrating my svn home-dir to git, mainly for the more transparent rename support, which i anticipate making it much easier to work naturally.15:55
Any particular gotchas that folks think I should be aware of? Managing 'subprojects' seems to be the biggest sticking point thus far.15:56
robfitz left15:58
CIA-11 joined15:59
Mikachu mithraic: don't accidentally type git-clean16:03
mithraic :)16:03
I'm still sorting out: if I want different bits to have different access privileges, they need to be in separate repositories, correct?16:04
Nindi joined16:08
Nindi If I do git-log --pretty=oneline the output is16:09
6e0ba847b5193aca66cd8e048f5b61da3fdc01ff16:09
1ca8c07ccf47bb39bc6e54fa0254ff46fa64aed516:09
73b4def933c53fb0c32e811b4b6d784b0a3177dd16:09
then if I do16:09
git-bundle create bundle e755..6e0b16:09
I get fatal: Refusing to create empty bundle.16:10
can anyone explain what I am doing wrong ?16:10
nessundorma Nindi, what does 'git log e755..6e0b' say?16:12
jlh left16:14
jlh joined16:14
CIA-11 left16:21
bdiego left16:24
madduck mithraic: http://lists.madduck.net/listinfo/vcs-home btw16:26
mithraic lovely, thanks!16:27
madduck mithraic: also, http://albatross.madduck.net/pipermail/vcs-home/2007-September/000095.html16:27
and about submodules: http://albatross.madduck.net/pipermail/vcs-home/2007-September/000096.html16:27
mithraic yeah, that's the one i'm reading :)16:28
madduck mithraic: colgit still has quite a bunch of issues16:30
and i really want to rewrite it in python, i think16:30
so if you're interested, i am looking forward to working with you.16:30
mithraic Thanks, I'll take a look at it, and consider my needs.16:31
bremac joined16:31
mithraic i have some crappy collection of shell scripts to manage a fleet of subversion homedirs at the moment.16:31
helping put together something for git would be great.16:31
CIA-11 joined16:38
dous joined16:40
engla Git, the information manager from hell: Deltifying 666 objects...16:41
bremac left16:43
bdiego joined16:52
dous_ left16:57
mithraic_ joined17:01
G_SabinoMullane left17:05
MadCoder gitster: morning ;)17:05
Beket joined17:07
cworth nud: Thanks for the fix. The source had underscores I'm quite sure, but the markup (markdown) must be eating them. I'll fix those soon.17:08
Ilari cworth: Also, '<' and '>' around one email address seemed eaten...17:14
CIA-11 left17:14
cworth Ilari: Thanks, I'll check that too.17:14
mithraic left17:17
Ilari cworth: It seems that it appears properly in code blocks, but not otherwise.17:18
nessundorma left17:18
mneisen left17:21
bentob0x joined17:23
Insount_awayInsount17:26
sheskar left17:27
CIA-11 joined17:28
Lash| joined17:33
Beket left17:36
orospakr left17:39
CIA-11 left17:40
alley_cat left17:46
CIA-11 joined17:50
radiomark left17:51
alley_cat joined17:57
mithraic_ left17:58
mithraic joined17:58
orospakr joined18:07
jaalto After pull, what does this command mean:18:17
.18:17
Warning: No merge candidate found because value of config option18:17
"branch.master.merge" does not match any remote branch fetched.18:17
No changes.18:17
.18:17
iabervon joined18:18
iabervon Anybody knowledgable about submodules?18:19
vmiklos jaalto you need something like git config branch.master.merge refs/heads/master18:20
jaalto vmiklos: what does that do?18:20
vmiklos it means that you want to merge the remote repo's master branch to your local master branch18:21
arwed joined18:21
alley_cat left18:22
lcapitulino joined18:23
jaalto vmiklos: Did that 'git config', but it still gives the same message18:24
Mikachu maybe you didn't create the local branch with --track18:25
jaalto I didn't. How can I proceed?18:26
vmiklos try git config branch.master.remote = origin18:26
Dodji joined18:28
jaalto vmiklos: Good. That made it. Thanks18:28
vmiklos: If you could spare a moment to explain what this exactly means:18:29
.18:29
[branch "master"]18:29
merge = refs/heads/master18:29
remote = vc18:29
.18:29
(I pull from alias "vc", not "origin")18:29
iabervon When you're on the branch "master", the default remote to fetch/pull/push is "vc", and the default thing to merge is "master" from that remote.18:30
jaalto iabervon: Clear. Thank you18:30
kumbayo left18:35
dduncan joined18:37
arwed left18:39
arwed joined18:43
chris2 left18:46
dous left18:48
dous joined18:49
KirinDave_ joined18:56
KirinDave_KirinDave18:57
CIA-11 left19:02
mnemoc joined19:04
CIA-11 joined19:14
lcapitulino left19:18
drizzd left19:21
KirinDave left19:21
CIA-11 left19:24
IRCMonkey joined19:26
alley_cat joined19:27
arwed left19:27
kelvie joined19:27
IRCMonkey Hi, if I want to access (read, git-cat-file), a previous version of a given file; I can do a git-checkout of the related commit; but if I just just cat the file, how could I do?19:30
vmiklos do you want to checkout a previous tree or get the contents of a given blob?19:30
IRCMonkey If I have the sha1 of a given commit, how can I find the sha of a given file in this commit?19:31
iabervon git cat-file blob <revision>:<filename>, if I understand you correctly.19:31
IRCMonkey get the content of a given blob.19:31
vmiklos or just git show <commit>:<path>19:31
IRCMonkey You did (understant correctly)19:32
fine19:32
Ilari IRCMonkey: Depending on what exactly you want do do with it, there may be easier ways....19:32
IRCMonkey show 1ea17ef25:Makefile, is this ok?19:33
CIA-10 joined19:33
IRCMonkey to see a previous version of my Makefile19:33
Ilari IRCMonkey: Yes, looks sane.19:33
IRCMonkey This way seems fine for the moment.19:34
thanks, see you19:34
Ilari IRCMonkey: 9 hex commit specification starts to break down at about 256K objects...19:35
IRCMonkey: Because at that point, collisions become likely and afterwards number of collisions increases quite fast.19:35
IRCMonkey Ilari: (back again) "9 hex specification", it meens "giving only the first 9 hex char of the sha1? Is that it?; By the way, if there would be a collision between two sha1, could it not check if they are equal or not? Like we do usually with a hash function?19:46
Ilari IRCMonkey: Yes, abbrevating commit ID with 9 first hex digits. The for full 40 digits, the breakdown point is approximately 1Y objects...19:48
alley_cat left19:50
Ilari IRCMonkey: Cryptographic hashes usually don't have collision checks.19:52
IRCMonkey Ilari: I saw somewere a function to calculate the git-sha of a given file19:54
because sha1 myfile, wont give me the correct answer19:54
iabervon git hash-object does it; there's a header and stuff.19:55
drizzd joined19:56
kristoffer_ joined19:56
IRCMonkey echo "toto"|git-hash-object --stdin ok19:58
ilari: could it be possible to do the processing git does to convert a file into an object by hand?20:00
And what about the converse processing?20:00
bdiego left20:01
Ilari IRCMonkey: The code to do it isn't terribly complex (as long one is talking about loose objects).20:01
IRCMonkey Yes loose objects20:01
for instance can you do some thing with "gunzip", on a bolb ?20:02
Ilari IRCMonkey: Basically, you need to convert to canonical format (by prepending headers) and then run it through zlib deflate compression.20:02
IRCMonkey: Which is _NOT_ the same as gzip compression (diffrent framing format).20:02
IRCMonkey If I calculate the length of the header (how), and prepend it...20:03
not the same, the same library?20:03
zlib20:03
But I need to do it in "c"20:03
iabervon It's the same compression method, but gzip puts different things on the very beginning and end.20:04
engla but the hash is of the uncompressed blob or unc blob + headers?20:04
IRCMonkey uncompressed, yes20:04
engla iabervon: how do you convince gzip to unpack an object manually?20:04
Ilari IRCMonkey: These headers contain <objecttype><space><size><nul>, where space is ASCII SPACE, nul is ASCII character 0, objecttype is one of 'blob', 'tree', 'commit', 'tag' and size is size of object expressed as ASCII number.20:04
iabervon I don't think gzip can be convinced.20:04
IRCMonkey <nul> : stop at the first nul char20:05
Ilary: zlib, not hard to use?, nothing special about it? That would be interesting to actually try.20:07
Ilari > echo -en "blob 0\x00" | sha1sum20:08
e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 -20:08
echo -n | git-hash-object --stdin20:08
e69de29bb2d1d6434b8b29ae775ad8c2e48c539120:08
mnemoc left20:08
IRCMonkey Ilary: that's cool20:09
engla Ilari: so headers are included in the hash. Which is probably sane..20:09
mutex left20:10
DrNick joined20:10
Ilari engla: One would need only to preturb object ID calculation with object type. The size does not really help much.20:10
IRCMonkey Convincing.20:10
engla Ilari: absolutely20:11
Ilari IRCMonkey: Actually, there are two loose object formats. The older (the one that is used) is just zlib compressed stream of canonical object representation.20:11
engla what is the other format? where is that used?20:12
Ilari engla: It is not used. Write support was removed (read support remains).20:12
iabervon The type has to be in the hash; otherwise, if you did "git cat-file commit HEAD > name; git add name" it would be unhappy trying to store a blob and a commit with the same hash.20:13
engla exactly20:14
I saw that git has code to detect collisions20:14
but since everything else is in place the only possibility is a sha1 collision20:15
we don't even have a test for that code path :)20:15
IRCMonkey engla; has it code to detect collision?20:15
iabervon Someday, somebody will find a sha1 collision, and we can use it...20:15
kristoffer left20:16
IRCMonkey engla: that's why I asked a way to calulate the sha : git-hash-object, to make the test myself20:17
engla index-pack.c: 33920:18
in branch maint20:18
die("SHA1 COLLISION FOUND WITH %s !", sha1_to_hex(sha1));20:18
:)20:18
Ilari engla: Not all SHA-1 collisions are useful to construct colliding git objects.20:19
engla exactly20:19
Ilari But should SHA-1 get broken to same level as MD5...20:19
z3ro left20:20
z3ro joined20:21
IRCMonkey engla: I don't understant: is there actually a collision test if I git-update-index a file?20:21
Ilari IRCMonkey: That collision check is AFAIK used only for fetches.20:22
mithraic Can someone devise a file whose first line is the SHA-1 hash of the entire file?20:23
That'd be a nice trick.20:23
Ilari mithraic: That would be very difficult. Much more difficult than collision...20:23
mithraic a kind of quine.20:24
engla I don't know where that function is used. but it just checks if we have that file already, and does a sanity check of size, type etc.20:24
Ilari mithraic: It is however possible to construct program that prints SHA-1 of its source code...20:24
mithraic without actually running the sha-1 algorithm on the source code?20:25
Ilari mithraic: That actually extends to machine language, so it is possible to write ELF file that prints its own SHA-1 hash. Without reading itself.20:26
evan joined20:26
evan why the heck is gitweb stripping all spaces?20:26
and emitting that it doesn't understand &nbsp;20:26
IRCMonkey Also, to be sure a move will be commited correctly, we can calculate the hash of the object after the move and compare with the one of the same object before. that must be the same.20:27
Ilari mithraic: Actually, it internally runs SHA-1 on reconstructed copy of itself.20:27
mithraic i see. so it's a classic self-quoting combined with a sha1 implementation. interesting.20:27
Ilari mithraic: All turing complete languages with unrestricted printing operators have quines.20:29
Nindi If I do git-log --pretty=oneline the output is20:34
6e0ba847b5193aca66cd8e048f5b61da3fdc01ff20:34
1ca8c07ccf47bb39bc6e54fa0254ff46fa64aed520:34
73b4def933c53fb0c32e811b4b6d784b0a3177dd20:34
then if I do20:34
git-bundle create bundle e755..6e0b20:34
I get fatal: Refusing to create empty bundle.20:34
can anyone explain what I am doing wrong ?20:34
evan left20:34
Ilari Nindi: What does 'git log e755..6e0b' return?20:34
Evelynn left20:35
Nindi one sec and I will find out20:35
Ilari: It shows me the cirrect commits20:35
Ilari Maybe you can't use non-ref as upper bound in bundles...20:35
drizzd left20:35
Nindi ilari that could be true becausgit-bundle create bundle e755..6e0be20:36
git-bundle create bundle e755..HEAD works fine20:36
but why ?20:37
Ilari Nindi: Bundles have refs too which pin commits inside bundle...20:37
Nindi Ilari: I don't underrstand that20:38
Ilari Nindi: Look at the created bundle file using something like 'less' (the part before the binary gunk begins).20:38
Nindi ilaria : ok20:39
am looking .. I can see two SHA IDs20:39
alley_cat joined20:40
Ilari Nindi: One of them has 'HEAD' after it, hasn't it?20:42
Nindi ilari : no -73b4def933c53fb0c32e811b4b6d784b0a3177dd cmmit 3 into 120:42
762e5a8dd8efa5498c5dadb8ee596fa6c1471eb1 refs/heads/master20:42
it only has20:42
-73b4def933c53fb0c32e811b4b6d784b0a3177dd cmmit 3 into 120:42
762e5a8dd8efa5498c5dadb8ee596fa6c1471eb1 refs/heads/master20:42
Ilari Nindi: Ah, of course. It resolves symrefs.20:43
Nindi cmmit 3 into 1 was y 3rd commit message20:43
ilaria : could you elaborate20:43
Ilari Nindi: It interpretted 'e755..HEAD' as 'e755...refs/heads/master', because HEAD is 'symbolic link' to refs/heads/master...20:44
IRCMonkey left20:45
Nindi ok , but that still doesn't explai Why I can't bundle all the cvommits between to SHAIDs20:45
Ilari Try running 'git ls-remote foo.bundle'.20:45
(Yes, bundles do have remote branches).20:46
madduck bundles?20:46
is that a new feature?20:46
Nindi it gives me20:46
762e5a8dd8efa5498c5dadb8ee596fa6c1471eb1 refs/heads/master20:46
Romster left20:48
Ilari madduck: Not new one: Author date is 20070222 005914 UTC...20:48
Nindi: Meaning that the bundle has one ref, named refs/heads/master, which points to 762e5a8dd8efa5498c5dadb8ee596fa6c1471eb1.20:48
madduck Ilari: ah yeah, now i remember.20:49
Nindi Ilari: ok ... are you saying the the upper bound must be a ref ?20:49
Romster joined20:49
Ilari Nindi: Yes. Upper bounds given apparently must be refs.20:49
Nindi ilari : why ??20:50
Ilari: is there a rational reason for that ?20:50
: ilar so taggin should work20:50
Ilari Nindi: Lower bounds don't have to be. The upper bounds need all to be named in the bundle.20:51
Nindi: In your case, there is one upper bound named 'refs/heads/master'.20:51
Nindi but thhe SHA IDs are ARE names20:51
Ilari Nindi: But there must be reference name too...20:52
Mikachu does it have to do with that you can only git-fetch named refs and not random sha1s?20:52
alley_cat left20:52
Ilari Mikachu: Exactly.20:52
Nindi ok Tagging worked20:53
Ilari Nindi: Even tracking branches (or even more exotic kinds of refs) can be used as upper bounds.20:54
Nindi I tagged a random commit .. and git-bundle create bundle 654...someTag worked20:54
cortilap left20:54
mutex joined20:56
Ilari Nindi: IIRC, there was some bug with bundling annotated/signed tags fixed some time ago...20:57
Nindi: First release containing fix was 1.5.3-rc5.20:59
Nindi Ilari: what exactly was the bug ?21:00
Ilari Nindi: As far as I can tell, It treated the annotated/signed tag as simple tag.21:01
Nindi Ilari: Am sorry .. but am quite new to git, so what exactly does that mean ... and what does it mean in terms of my problem ?21:03
Ilari Nindi: It is not related to that can't-use-numeric-IDs-for-upper-bounds problem21:03
Ilari_ joined21:04
Ilari left21:04
Ilari_ left21:04
Ilari joined21:05
Ilari hit the wrong button...21:05
clausen joined21:07
clausen th21:07
hi all21:08
mutex_ joined21:08
Ilari Nindi: In practice it meant that if commit was signed via the tag, the signature was lost, as well as other explanation introduced via that tag.21:08
clausen is there an easy way to start a new repository from some pre-existing files21:08
with "push/pull"21:08
(the new repository should be "bare")21:08
Ilari clausen: 'git init' 'git add .' 'git commit' (run in the directory with files).21:08
clausen Ilari, that wouldn't be bare21:09
I have been doing this:21:09
Ilari clausen: Then create new bare repository (git --bare init --shared) and push the created repostory there.21:09
clausen ah21:09
great21:09
will git automatically know where to push/pull from?21:10
Ilari clausen: Or if it is updated only by you, you can omit the --shared.21:10
clausen what does --shared do?21:10
ah, just permissions21:10
Ilari clausen: Sets shared mode, in which git forces group access flags to match user access flags in files it creates inside repo.21:10
clausen: A way to override umask.21:11
clausen yeah, I just rtfm :)21:11
Ilari clausen: It might be easier first to create remote for the new bare repo (git remote add) and then 'git push --all'.21:12
clausen: Actually, 'git push <remotename> --all'.21:12
CIA-10 left21:13
Ilari clausen: Then one can update what's there with 'git push <remotename>', or 'git push <remotename> <branch>' to update/add branch.21:14
clausen here's another way to think about it:21:14
I have a full repository21:14
I make a bare clone of it21:14
(git-clone --bare project project.git)21:14
and then I want to make push/pull default to "project.git"21:14
Ilari clausen: In 'project', add project.git as remote using 'git remote add foo ../project.git', where foo is name of remote.21:15
clausen: The default used by push/pull is 'origin' unless overriden per-branch.21:16
clausen Ilari, does that make it default?21:17
I guess I should just try it :)21:18
ah, thanks21:19
I think many / most people would like a setup like I suggest21:19
it seems like it should be in an FAQ or something21:19
jaalto When I merge, and get conclicts -- it is possible to say "replace" from the the merge source?21:20
gitte joined21:20
jaalto That is, I don't want to preserve local changes, but the file woudl be pulled from the merge source21:20
Ilari jaalto: IIRC, :3:path/to/file is expression for SHA-1 of version of file from branch being merged.21:20
Lash| left21:21
jaalto What's that :3: thing=21:21
Ilari jaalto: Meaning look for file from index stage 3.21:21
jaalto ok21:21
Ilari jaalto: Normally 1 is ancestor, 2 is yours, 3 is theirs. But in one place (rebase), 2 and 3 seem to be swapped...21:22
mutex left21:23
jaalto So I run (after conflict message):21:23
git checkout HEAD -- :3:path/to/file21:23
Ilari jaalto: I don't think that will work... More like 'git show :3:path/to/file >path/to/file'...21:24
engla how suitable is the bundle format for transferring git repositories? Wouldn't that be the "native" way to compress and store a whole repository21:25
jaalto Ilari: ok21:25
Ilari engla: It doesn't store config (including remotes) or reflogs...21:25
engla: But otherwise it stores the exact objects.21:26
engla true. It only stores all objects and the ref at the tip.21:26
it can be unbundled in an empty repository. Then you check it out with the funny message "warning, you seem to be on a branch yet to be born"21:27
CIA-11 joined21:27
iabervon You should be able to clone it, although that would leave an odd remotes config.21:28
(Not to say that you *can* clone it, but...)21:28
clausen this didn't work: git-remote add origin ../project.git; git-pull21:34
it fails:21:35
Warning: No merge candidate found because value of config option21:35
"branch.master.merge" does not match any remote branch fetched.21:35
Ilari clausen: 'git config branch.master.merge refs/heads/master' 'git config branch.master.remote origin' (if I recall correctly).21:36
moh_ joined21:36
segher_ joined21:37
gitte Or do the more correct thing: git checkout -b master origin/master21:37
clausen Ilari, that worked... but isn't there an easier way?!21:37
moh left21:38
Ilari clausen: What gitte said above21:38
clausen why -b master?21:41
gitte 'cause you are technically branching off a new local branch.21:41
clausen that would "create" a new branch ,right?21:41
weird21:41
gitte Why weird?21:41
I assume you did not clone that repo, right?21:42
clausen yes, I did21:42
gitte Otherwise you just overwrote "origin".21:42
clausen basically, I want to use git like cvs21:42
I want to create a central repository that I push/pull from21:43
it seems non-trivial to do this21:43
I suppose I haven't played with branches in git21:43
PerlJam clausen: what makes you think it's non-trivial?21:49
clausen: just that you don't know how?21:49
clausen I don't know :)21:50
it certainly isn't documented21:50
Mikachu if you clone a bare repo, then clone a non-bare repo from that, the new repo should have origin all set up to push/pull from the bare repo21:50
s/clone/clone to/g21:51
clausen Mikachu, good point, but that's still non-trivial :)21:51
(it's still the simplest way I know. thanks :)21:51
Mikachu well, you're not supposed to start from a non-bare repo with no origin i guess :)21:51
clausen what does "repo with no origin" mean?21:52
Mikachu btw, i think you would want to move all refs from refs/remotes/origin to refs/heads in the to-be-central repo before you clone from it again21:52
one that you just git-init21:52
clausen ah21:53
so, how else do you start?21:53
Mikachu i guess the other way is to git-init the bare repo first and clone from that21:53
feel free to stop me if i'm saying crazy things, anyone :)21:54
gitte clausen: I have to admit that I wanted to suggest to you to stick with cvs, since you want to use git like cvs.21:54
clausen: but your suggestion that it is non-trivial suggests that you have not read the tutorials...21:55
clausen no way21:55
cvs *sucks*21:55
git completley dominates it21:55
(eg: commitng locally is great)21:55
gitte So why do you want to stick with cvs _mindset_?21:55
clausen I haven't found a clear description of the git "mindset"21:55
vmiklos even after reading the user manual? :)21:56
gitte (Actually, you did not really... in CVS you do not checkout a project into the same directory from which you imported it...)21:56
Oejet left21:56
gitte So whenever you clone from somewhere, the config is all set up for pulling.21:57
No magical git incantation needed.21:57
clausen vmiklos, the manual is rather uninformative about day-to-day usage of git21:58
vmiklos, perhaps it would be good if it told some stories :)21:58
gitte I guess your problem was that you actually pushed to a freshly initiated "upstream", and thought that it was set up to pull from there, too.21:58
vmiklos clausen have you read the "everyday with git" document, too?21:58
iabervon We've never gotten around to writing a script for "reverse clone", so you have to do the ~5 commands by hand.21:58
gitte Hey iabervon! Thanks for the builtin fetch...21:59
vmiklos clausen http://www.kernel.org/pub/software/scm/git/docs/everyday.html <- quite useful to start21:59
clausen vmiklos, yes21:59
gitster thanks daniel too.21:59
iabervon You're welcome.21:59
clausen vmiklos, I didn't find it very helpful21:59
vmiklos, I would prefer it if it were written in the style of "a day in the life of a kernel hacker" or something22:00
gitster Is clausen a kernel hacker?22:00
clausen no :)22:01
(I did some kernel hacking about 5 years ago, but that's ancient history)22:01
vmiklos parted:)22:01
clausen you can stalk me here: www.econ.upenn.edu/~clausen22:01
that too :)22:01
vmiklos and the pagerank wizard;)22:01
clausen (although, I must confess that parted isn't the most brilliant program ever...)22:01
gitster I am not particularly interested in what you are. I asked it because such a document exists (by Greg KH -- ask google) and I suspect it might be more useful to the kernel people than users on other projects.22:02
clausen I'm actually using git to write academic economics articles22:02
gitte clausen: so how about this: you describe what you want to do, we help you, and you write that document you wished for?22:02
Mikachu it's impossible to read that green link text on the gray background22:02
gitster I would freely admit that the documentation set we currently have are definitely geared towards majority of audiences we have picked up recently.22:04
clausen gitte, simplify "git-clone project project.git; rm -rf project; git-clone project.git project"22:04
(well, that's the immediate concern)22:04
PerlJam clausen: you know, you're the first person I've heard who is using git to track changes to articles (I'm doing the same myself)22:04
gitster The oldest part are mostly for people who hack git, and then newer parts are for people who hack their code _and_ are willing to customize git for their taste while git hasn't really matured.22:04
clausen I haven't used any branches, although that probably would come in handy22:05
Mikachu are the articles in a text format?22:05
gitte clausen: I think that the two "git config" lines that "git pull" suggests are not only descriptive, but they also help you _know_ what you can do.22:05
clausen: namely, adding other upstreams.22:06
PerlJam: I do that, too. Even articles I did not write myself: Even articles written in OpenOffice)22:06
clausen Mikachu, latex22:06
gitte clausen: I do not think that this is a common use case, but we could easily add a "--push" option to git-remote: "git remote add --push origin <url>"22:09
clausen gitte, how do you usually expect people to start a new project?22:09
gitte I do "git init".22:09
That's it.22:10
clausen do you have 1 computer?22:10
CIA-11 left22:10
gitte ATM yes.22:10
clausen would you just do git-init if you worked from 3 different computers?22:10
PerlJam clausen: he'd do it at least once :)22:11
clausen (eg: students often work from home or school)22:11
gitte For backups, I initialise empty repositories, and I _do_ add them with "git remote add <nick> <url>"22:11
clausen PerlJam, how do you sync up?22:11
gitte And because I have several sites to pull from, I usually call "git pull <nick> <branch>"22:11
Just to be sure that I pull from the correct machine, the correct branch.22:12
PerlJam depends on which side I'm on. either push or pull :)22:12
gitte Without having to check everytime what the config says.22:12
clausen I'm not sure I undestand22:13
gitte clausen: I am paranoid.22:13
clausen I have 1 copy of the master (on www.econ.upenn.edu)22:13
gitte I have backups on three different computers.22:13
clausen if I screw up, it fails nicely22:13
gitte (Three in addition to _mine_)22:13
PerlJam I do wish there was a "git sync" or something that would make two repositories identical.22:13
gitte And I actually _work_ on them, too.22:13
PerlJam Maybe something like that exists and I just don't know about it though22:13
clausen if I forget to git-commit or git-push or git-pull, git gives me nice error messages to remind me22:14
gitte PerlJam: huh? Define the semantics first.22:14
clausen git-pull; git-push ?22:14
Mikachu like that git-mirror thing someone mentioned the other day?22:14
or cp -a? :)22:15
clausen gitte, so, is there a way my configuration can screw up?22:15
gitte clausen: so with the different computers, I say _exactly_ from where I want to pull, and which branch. Makes things much more clear in my head.22:15
clausen with my approach, I don't need to think22:16
gitte git-mirror is about having a bare repo tracking another repo.22:16
clausen: oh.22:16
clausen: what was that quote about that?22:16
gitte goes and searches it...22:16
clausen well, I'm asking if there's any way "not thinking" can screw things up :)22:16
engla git clone --mirror perhaps?22:16
clausen btw, I haven't found greg kh's git howto on google22:17
gitte "not thinking" always screws things up.22:18
vmiklos git-mirror? :)22:18
clausen is it this? http://cs343-spr0607.stanford.edu/index.php/Writeups:Greg_Kroah-Hartman22:18
vmiklos didn't you mean git remote add --mirror?22:18
gitte Well, I did not find the quote, but here is another one: "Human beings are not only unique in their ability to think, but also in their unwillingness to do so"22:18
clausen gitte, for example, I like logging in non-priviledged, because it means I can't break my machine22:18
gitte, it means I don't need to think as much22:18
gitte vmiklos: git-mirror predated "git remote add --mirror" quite some.22:18
clausen gitte, when I'm roote, I fear my machine, and have to think22:19
gitte vmiklos: and "--mirror" is not in any official release yet.22:19
Mikachu clausen: if you find anyone who logs in as root, hit them on the head for me22:19
clausen gitte, it's nice to not have to think22:19
bish0p joined22:19
vmiklos hm22:19
$ git mirror22:19
clausen Mikachu, my argument is, "not having to think" is a virtue22:19
vmiklos git: 'mirror' is not a git-command22:19
Mikachu btw, all files that you care about are owned by your user, the things root can destroy are fixable by inserting a live cd and installing some packages again22:19
clausen Mikachu, and unix's design of not being root is good for this reason (among others :)22:19
gitte clausen: I'm sorry, but I will always discourage people from "not thinking". _I_ think it is wrong.22:20
vmiklos: git-mirror is a script by pasky, IIRC22:20
vmiklos ah22:20
vmiklos googles22:20
clausen gitte: when you download email, do you "think" about where your mail server? your network connection? your router?22:20
engla clausen: if something happends you can mostly recover from it easily. Like using git reset to undo a wrong pull/merge22:20
Mikachu vmiklos: http://thread.gmane.org/gmane.comp.version-control.git/2772622:21
that's the link i saw the other day in here anyway22:21
gitte clausen: in any case, I think it is not really warranted to call three commands to set up your particular needs on _one_ machine "complicated"22:21
clausen engla, that's my experience... git is very friendly when you forget to git-push, git-pull, or git-commit22:21
vmiklos Mikachu thanks:)22:21
so this is something hot new:)22:21
gitte clausen: remember, if you clone from your "upstream" (which will be the case for _all_ except the first one), it is all set up by git-clone.22:21
Mikachu vmiklos: actually it's an old patch that never got merged :)22:21
clausen gitte: I think it's complicated22:22
aroben joined22:22
vmiklos eh:)22:22
vmiklos read 2007 instead of 200622:22
clausen gitte, I probably wouldn't have thought of it myself22:22
(since it's the first thing I tried doing, I didn't have much intuition about how things worked...)22:22
gitte clausen: if you think that those two "git config" lines (that are suggested by the failing pull!) are complicated, I fear I cannot help you.22:23
clausen how are they suggested by the failing pull?22:24
CIA-11 joined22:24
clausen firstly, I haven't learned about branches yet22:24
I think it's unreasonable to expect new users to learn branches at the start22:24
(the git-pull failure message talks about branches)22:25
Mikachu branches are very fundamental when talking about pushing and pulling22:25
clausen AFAIK, I only have 1 branch22:25
gitte clausen: basically, what you did is not usually what you do as a new user of git.22:25
clausen so, they aren't fundamental in my case22:25
gitte What you do is _clone_ from somebody.22:26
clausen why would a new user clone from somebody?22:26
gitte Not set up an upstream, and then set that up to be pulled from.22:26
clausen are you claiming it's uncommon for a new user to start a new project?22:26
gitte clausen: because you do not set up new repos everyday.22:26
clausen: I'm not claiming that.22:27
clausen: I am claiming that setting up an _upstream_ is not what a new user of git does right away.22:27
And I really have to caution here: if you set up an upstream, but do not understand branching, you will not be happy.22:27
clausen I think it should be typical22:27
if you have many computers to work from22:27
(eg: laptop + desktop)22:27
gitte For example, you might still have the impression that you all work on the same branch.22:28
Well, here's some news for you: you don't.22:28
clausen can you give an example of some semantics I wouldn't expect?22:28
gitte Face it: most new git users are cloning an existing project.22:28
clausen: try to check out a remote branch (i.e. origin/master in your case).22:29
You'll be in for a surprise.22:29
clausen I've been using this configuration for about a month with no trouble, pushing and pulling 100s of times22:29
gitte You did not "git checkout origin/master".22:30
clausen correct22:30
gitte That was what _I_ was saying. You'd be surprised.22:30
Actually, you can try that right now (if you have no uncommitted changes)22:30
clausen obviously, I wouldn't try it on my working repositories...22:31
gitte You could.22:31
It's safe.22:31
It's git.22:31
clausen I trust you, but I'll do it on a toy repo anyway :p22:31
nud git makes it easy to fix a broken repo ;-)22:31
gitte used to run git-fsck --full twice a day for a while; now it is only once a week22:32
clausen (that way, I don't need to think!)22:32
nud (at least when brokenness is related to branches and heads)22:32
Mikachu i think it's a bit too easy to delete a tag :)22:32
gitte clausen: if you keep saying that you don't want to think, I'll stop... ;-)22:33
clausen I don't want to think about losing/repairing data :)22:33
gitwump clausen, out of interest, which tools did you use previously, eg did you use darcs or arch?22:33
gitte gitwump: heh, nice nick!22:34
clausen gitwump, I just kept a tarball of every version22:34
pasky repo 13877 0.0 0.0 3296 1052 ? SN Sep29 0:00 | | \_ git-peek-remote git //git.icculus.org mikachu/openbox22:34
Mikachu :O22:34
pasky wishes again that git would time out in some sane fashion22:34
rodserling joined22:34
clausen gitwump, I used cvs a bit, but screwed up too much22:34
Mikachu i think that server is currently a bit down22:34
gitwump ok. Interestingly, before BitKeeper, that was Linus' only VCS too :)22:34
gitte, thanks22:34
pasky sometimes these hanging gits are blocking the mirroring process for days22:34
clausen gitwump, in particular, my internet access is very spotty, so cvs didn't work in that case22:35
gitwump yeah, that's a big issue with centralised systems for those on the fringe of the interner22:35
-r+t22:35
gitte gitwump: remove "read", add "sticky"?22:36
gitwump it's another irc form for "s/r/t/" but applies to wherever it needs to22:36
Mikachu i like s/interner/internet/ since it takes less parsing to understand what you mean22:37
mithraic Can I have nested submodules? Documentation is still a little scarce on the ground.22:38
Ilari mithraic: Yes.22:39
gitte mithraic: Why shouldn't you?22:39
pasky: it'd involve a patch to xread() in git-compat-util.h, I guess...22:39
mithraic Well, I'd hope so, but wanted reassurance.22:39
iabervon Nested submodules work, but they're unweildy.22:39
clausen gitte, can you please tell me how git-checkout can surprise me?22:40
pasky gitte: yeah, probably22:40
janm left22:40
gitte pasky: you'd have to select() with a given timeout, and in the timeout case, die().22:40
pasky or just alarm()22:40
gitte clausen: it'd make you think, I fear ;-)22:41
clausen gitte, that's what I'm scared of :p22:41
bring it on!22:41
mithraic and is it reasonable to create a submodule 'in-situ', rather than creating it elsewhere and then referencing it from there?22:41
clausen ah, I see22:41
gitte pasky: alarm() is not so good, methinks... you'll have to _unset_ the timer in case of success, with setitimer().22:42
pasky: so maybe better be explicit about it with select(), no?22:42
iabervon I don't think there's a script for turning a directory into a submodule.22:43
Ilari mithraic: Yes. Just create git repository, commit something there, and then git-add the directory.22:43
clausen git-checkout took me off the "master" branch?22:43
mithraic Great! So this makes partial checkouts pretty feasible, then!22:43
gitte iabervon: that's right; the beginnings of it are in filter-branch --subdirectory-filter, though.22:44
Ilari mithraic: Actually, that is pretty much the only submodule-related user-level operation that works in 1.5.2...22:44
gitte clausen: exactly, because "git checkout" is about switching branches.22:44
(In general.)22:44
clausen but, if you ignore branches, that will never happen :)22:45
gitte And your statement "I'm not working with multiple branches" is provably wrong... for each repo you have, you have an independent set of branches.22:45
So whenever you clone, you branch off.22:45
Mikachu that's a slightly confusing thing about git, half the commands are overloaded with unrelated functions for convenience :)22:45
clausen how so?22:45
gitte clausen: whenever you make local changes, you branch off.22:45
clausen: that's true for _every_ SCM; we are just honest about it.22:46
clausen what does git-push do then?22:46
gitte Mikachu: if you want simple, why not go mercurial? *ducks*22:46
pasky bah22:46
:)22:46
Mikachu i'm not saying it's bad or that i want something else, just that it's confusing :)22:46
pasky git should be simple22:46
gitte clausen: git-push updates a remote branch to the state of your local branch.22:46
pasky: I find it simple.22:46
pasky many people don't22:47
I don't, for one :)22:47
gitte pasky: but there are people who say "it should be simpler"... nevertheless, most seem to be incapable of proposing sane simpler semantics...22:47
clausen I suppose I should just play around with branches to learn about them22:47
here's a proposal:22:47
git-push and git-pull should have an option called --set-default that sets the default places to push/pull from22:48
engla git should continue to strive to be simpler22:48
Mikachu i think it would perhaps be a bit helpful if the "plumbing" commands were either in /usr/libexec out of the normal path, or named git-plumbing-*, or something22:48
clausen (origin/master ?)22:48
iabervon origin/master is the branch that stores the latest information you have about origin's master branch.22:49
kristoffer_ left22:49
gitster clausen: there already is "setting the default places to push/pull from".22:50
Read about branch.*.origin and branch.*.merge options.22:50
Mikachu he doesn't want to know about branches or git-config, it seems22:50
clausen gitster, IMHO there should be no git-config command22:50
gitwump clausen, git-push and git-pull are having their operation rethought for 1.6, so now is a good time to participate in the ML discussion22:50
engla using --track with checkout should do that I think?22:51
gitster You just need to learn what people have already worked hard to prepare for you, before proposing something new and useful.22:51
And I do not particularly think "I'll play with branches a bit more" is useful.22:51
gitte clausen: there should be no git-config command? That is really not thinking... ;-)22:52
gitster If you have two repositories and pushing-fetching between them, then you are already playing with branches.22:52
Mikachu git-dwim should be the only git command22:52
gitster Heh, why then use git? The only command you need is "write-perfect-paper-or-code-for-me".22:52
gitwump with darcs, arch, bzr, they call it branches when you make a complete copy of the repo22:53
gitster You use the output of that command. No revision control necessary ;-)22:53
gitwump git-config most of the time feels more like plumbing22:54
not really a user command. It doesn't know what keys are valid for a start, so it doesn't really do much checking of its arguments22:55
which is arguably how it should be22:55
mithraic Ummm, permission to ask a very dumb question? Once I've done the no-no of git-pushing to a repository that has a working copy, how do i update that working copy?22:55
gitster If you did not have any precious local change, "git reset --hard HEAD".22:55
gitwump mithraic: use git diff to check you didn't have any local changes, then you can git reset --hard22:56
mithraic thanks kindly :)22:56
Ilari What about 'git set-tracked-branch' for that one case? Or it is just too rare to matter?22:56
gitwump well it might be an option to branch or pull22:56
eg git pull origin branch --set-default22:57
Ilari gitwump: Yes, that is probably better.22:57
gitwump People already think there are too many commands :)22:57
Mikachu more options to existing commands are fine i think :)22:57
gitte gitster: wouldn't "git read-tree -u -m HEAD" been better?22:58
Nindi left22:59
gitte gitwump: FWIW the idea is not new: http://article.gmane.org/gmane.comp.version-control.git/1933722:59
Mikachu isn't that git-remote add?23:00
gitster I do not quite get that whole thing. Are you guys complaining that there is no easy way to change what a "git remote add" sets up?23:01
clausen why is git-checkout called that?23:01
wouldn't a better name be git-branch-select?23:02
gitster You "checkout a branch".23:02
Learn the lingo of the land.23:02
Mikachu you can checkout things that are not branches too23:02
clausen git-branch-checkout?23:02
ah23:02
thanks23:02
gitster And it is not unique to git -- cvs checkout, svn checkout, etc.23:03
engla cogito had "switch" (?)23:03
sounds good to switch branch. I do that a lot23:03
gitster That's the oddball and it died because of its "uniqueness" ;-)23:03
clausen gitster, "cvs checkout" is more like "git pull"23:04
Mikachu switching branches is switch in svn too iirc, checkout means to clone branch tip and check it out :)23:04
gitster clausen: I suspect you are thinking about "cvs update".23:04
clausen gitster, oops. I meant "git clone" I suppose23:04
gitte clausen: that git-config thing you hate so much helps you here: git config --global alias.branch-select checkout23:04
gitster clausen: Ah, Ok, it is more like "git clone".23:04
gitte: but then you can also "branch-select a file out of a different commit".23:05
Mikachu even if it's not the same as the checkout from cvs and svn i think it's an appropriate name for what it does23:05
gitster We usually say "checkout that file from this commit".23:05
So try to resist the urge of "improving" things before you understand how the world currently works. It will not help you.23:06
gittish the inconsitency there is that if I leave out the path it changes HEAD23:06
gitster gittish: that's not "inconsistency" -- it is just "use of overloaded word".23:06
You either "checkout the branch", or "checkout the path out of the branch".23:06
The verb checkout is working on different objective noun in these two sentences.23:07
gittish the only difference is an extra parameter23:07
normally that would mean "optional"23:07
gitster The only difference is "the path out of the".23:07
clausen gitster, I think trying to improve things is a good way to figure out how the works23:08
gittish I know what it means, and you know what I mean. I still think it is confusing.23:08
mithraic Okay, so with nested submodules, it looks like I need to manually recurse and do a git-submodules init && git-submodules-update.23:09
gitster That's because the word "checkout" in human language is already overloaded. We could call the former operation "git frotz" and the latter operation "git nitfol" if that would make you feel better ;-)23:09
gittish :)23:09
iabervon I think it's a bit odd that you can't change branches using "git branch".23:10
mithraic Yeah, that kind of pulls against intuition.23:11
gitster Yeah, and it is very odd that you have to say "git branch -d"; more natural "git chainsaw" does not work.23:11
iabervon Well, everything else you might want to do with branches can be done with "git branch", so it's a logical place to look.23:12
gitster well if we do not have "git checkout" and have you "git branch --switch", we would please only people whose first (and only) SCM is git.23:12
clausen does git-push only push the selected branch?23:13
iabervon (and the "git chainsaw" alias is easy to make, while connecting an existing function to an existing program)23:13
gitster Doesn't git-push(1) describe that enough?23:13
If you tell it what to push, it pushes them and nothing else.23:13
Mikachu iabervon: git-branch doesn't do anything else with the work tree so i think it would be strange if it had one subcommand that did that23:14
it only juggles around thnigs in .git/refs23:14
gitster If you don't there are set of rules to choose the default things to be pushed.23:14
iabervon FWIW, users of other SCMs are too afraid of branches to want the feature at all.23:14
clausen gitster, no. git-push(1) just says "update remote refs using local refs"23:14
gitster, it doesn't say which local refs23:14
(you can have "refs" -- whatever they are -- on many branches, right?)23:14
Mikachu surely it mentions almost at the top "Note: If no explicit refspec is found, then all the heads that exist both on the local side and on the remote side are updated."23:15
gittish a branch *is* a ref23:15
gitster I did not ask "doesn't the first line of git-push(1) tell everything?". Obviously there is not enough room.23:15
Mikachu maybe scrolling down counts as thinking23:16
gitster goes back to 1.5.3.323:16
gitte gitster: one question before you leave...23:16
clausen gitster, the DESCRIPTION part of git-push(1) is literally 3 sentences23:16
Mikachu back to the future?23:16
gittish "description" fits on the first page, unless you are running on an old cash register or something23:16
gitte gitster: what did you mean by "gitlink" feature?23:17
gitster: is that the core functionality behind submodules?23:17
gitster bind html branch out of git.git as a subproject to WinGit.23:17
clausen (isn't it common for DESCRIPTION to be several pages?)23:17
gitte gitster: ah, but do I not need a symlink then?23:17
gitster: forget what I just said. alternates are enough.23:18
Mikachu clausen: if you wonder what the command does when the optional paremeter 'refspec' isn't given, isn't it natural to scroll down to the description of that option and see what it says?23:18
gitte git-dont-make-me-think? ;-)23:18
gitster I am actually not _actively_ suggesting to use the subproject for WinGit at this stage, yet.23:18
iabervon clausen: only if you don't have OPTIONS as a separate section.23:18
edalytical joined23:18
clausen ah, fair enough23:19
gitte gitster: and I maintain that it would be actively wrong to have a subproject for WinGit.23:19
gitster: but having the html branch checked out as a submodule makes sense.23:19
gitster the difference between the two escapes me, sorry.23:19
gitte gitster: WinGit is just the installer (without dev env)23:20
dash__ joined23:20
gitster Can somebody add "git push" without any parameters to the Examples section of git-push.txt please?23:20
gitte gitster: so ATM we have everything needed for it in /share/WinGit/23:20
Mikachu but Examples is at the bottom, surely nobody scrolls down that far ;)23:21
gitster gitte: ok, then I probably meant mingwgit or gitme or whatever it is called these days.23:21
gitte gitster: I'm sorry... lemme explain in one sentence:23:21
edalytical hi everyone, does "git status" respect the configuration variable core.excludesfile?23:21
clausen what's the difference between git-push and git-push --all?23:22
gitte gitster: msysgit.git contains the complete dev env, with "git" as a submodule. The scripts to make the installers are in /share/WinGit/, /share/msysGit/ and /share/GitMe/.23:22
gitster Mikachu: quite the contrary. Lazy and overconfident people including me are known to skip the description section and go right to the Examples section, expecting that it is enough to learn from examples.23:22
clausen oops23:22
Mikachu clausen: presumably it pushes even refs that aren't already in the remote23:22
clausen I misread23:22
thanks23:22
gitte Mikachu: I agree with gitster here; I often only read the examples section.23:22
gitster So I would not blame people not reading descriptions section and wonder why things do not work as they expect. I do that to other people's software.23:23
kreaturr is there a way to pick merge or cherry pick between branches - but just for one file?23:24
gitster But descriptions and options sections are exactly for these people, when the law of the land is _NOT_ what they thought was, to find it out.23:24
kreaturr: if you are doing "just for one file", that is not a merge nor a cherry pick.23:24
Having said that, "git diff ...that-branch -- this-file | git apply --index" would probably be what you are looking for, to grab the change that-branch made to this-file and apply it to your current branch.23:26
clausen is this synposis correct?23:26
Mikachu kreaturr: you could cherry-pick -n and git-add only the file, then reset --hard23:26
clausen SYNOPSIS23:26
git-pull <options> <repository> <refspec>...23:26
shouldn't it be:23:26
SYNOPSIS23:26
git-pull [<options>] [<repository>] <refspec>...23:26
Mikachu possibly gitster's command is more foolproof23:26
gitte kreaturr: you can write the contents in the different revisions (branch1, branch2, merge base) into files and use git merge-file.23:26
iabervon clausen: they're actually all optional, and repository is required if you have a refspec.23:27
kreaturr well, "one file" is an example for a limited subset. thanks for the suggestions, those should work! :)23:27
clausen git-pull [<options>] [<repository> <refspec>...] ??23:27
gitte So git-pull [<options>] [<repository> [<refspec>...]]23:27
Mikachu i think if there is only one <> inside a [], just [options] is the standard notation23:27
gitster gitte: yeah, except everybody understands ... is 0 or more so [] around it is unnecessary.23:28
gitte kreaturr: I like Mikachu's suggestion better than mine; please ignore mine.23:28
Mikachu if we are being pedantic23:28
gitte is not pedantic and goes back to real work...23:28
iabervon I thought ... was 1 or more, in general.23:29
Mikachu git-pull [options] [<repository <refspec>...] then?23:30
although i guess that is incorrect if you can say just git-pull remote-foo23:30
gitster I think that was what clausen suggested. To avoid 1 or more vs 0 or more confusion, it would not hurt to have [] around refspec...23:30
Mikachu the only input i really have is to not write [<foo>] :)23:31
dash_ left23:32
Mikachu gitster: speaking of pedantic, did you miss the mail i sent about the type in the git-svnimport manpage? http://git.mikachu.ath.cx/?p=git.git;a=commitdiff;h=typo :)23:33
actually... that should say "higher than the" i think23:34
and specifies23:34
Fullmoon joined23:34
Mikachu the typo stands out so much i didn't even read the sentence before :P23:34
i guess i can proof read the whole page just as well23:35
would you say "an SVN repository" instead of "a SVN repository"?23:35
engla left23:36
Mikachu are double spaces ignored in asciidoc?23:36
edalytical I figured it out, core.excludesfile can't be set to an arbitrary file it has to be ~/.gitignore23:37
is this a bug?23:38
iabervon Are you sure you aren't overriding it with a different config file?23:39
dooglus left23:41
gittish does the whitespace=strip option to apply strip all trailing whitespace or just the ones introduced by the patch?23:41
ah, it says there..23:42
clausen does git-clone copy all branches?23:42
gitte edalytical: I don't believe that.23:42
elmex_ left23:42
gittish core.excludesfile can be any file23:43
edalytical I had it pointing at a different file and my where still shown in 'git status'23:43
changed it to ~/.gitignore and it worked as expected23:44
Mikachu gitster: okay i've updated it with some more fixes now, so it's less trivial23:44
clausen (it didn't copy all of my branches when I tried it)23:44
gittish edalytical: I have it set to another file in a number of repos23:45
Mikachu clausen: it does, but it puts them in remotes/origin/* instead of refs/heads/*23:45
clausen: see git branch -a23:45
edalytical ok, i'll check and make sure I didn't make a mistake23:45
iabervon edalytical: If you have it as something else, and you do "git config --list", does it look right?23:45
edalytical iabervon: it looks right and it also works23:49
iabervon Oh, okay, then.23:50
edalytical I must of had a typo in the path23:50
Mikachu that always happens to me, i make some silly mistake and then declare there's a bug :)23:50
edalytical should an error be reported if the path doesn't exist?23:51
gitte edalytical: is an error reported if .git/info/excludes does not exist?23:58
Mikachu it's possibly not quite the same23:58
gitte why?23:59
Remember, you can set it in ~/.gitconfig23:59
iabervon One would assume that, if you specify a non-empty filename, it's because you intend to use it.23:59
gitte Again: you can set it in ~/.gitconfig23:59

Logs Search ←Prev date Next date→ Channels Documentation