Update Friday, 19th of June, Anno Domini MMIX, at the hour of the Monkey
[git/dscho.git] / index.html
blob2ce75291164019c31479b5b06e8f7b4c6e1d1671
1 <html>
2 <head>
3 <title>Dscho's Git log</title>
4 <meta http-equiv="Content-Type"
5 content="text/html; charset=UTF-8"/>
6 </head>
7 <body style="width:800px;background-image:url(dscho.git?a=blob_plain;hb=c33212b23b2b3e45c14403efe82cabb1cd53f6e3;f=paper.jpg);background-repeat:repeat-y;background-attachment:scroll;padding:0px;">
8 <div style="width:610px;margin-left:120px;margin-top:50px;align:left;vertical-align:top;">
9 <h1>Dscho's Git log</h1>
10 <div style="position:absolute;top:50px;left:810px;width=400px">
11 <table width=400px bgcolor=#e0e0e0 border=0>
12 <tr><th>Table of contents:</th></tr>
13 <tr><td>
14 <p><ul>
15 <li><a href=#1245419588>19 Jun 2009 The GraphGUI project</a>
16 <li><a href=#1242408298>15 May 2009 Wasting way too much time on msysGit</a>
17 <li><a href=#1241995759>11 May 2009 Working on jgit diff</a>
18 <li><a href=#1239975597>17 Apr 2009 No time for Git</a>
19 <li><a href=#1238970571>06 Apr 2009 How to recover from a hackathon</a>
20 <li><a href=#1236554268>09 Mar 2009 So, what is missing from my <i>rebase-i-p</i> branch?</a>
21 <li><a href=#1236479389>08 Mar 2009 New Git for Windows version</a>
22 <li><a href=#1235092615>20 Feb 2009 Code reviews</a>
23 <li><a href=#1234409395>12 Feb 2009 Interactive <i>rebase</i> just learnt a new command: <i>topic</i></a>
24 <li><a href=#1234320806>11 Feb 2009 Thunderbird, oh Thunderbird, you always make my small brain hurt</a>
25 </ul></p>
26 <a href=dscho.git?a=blob_plain;hb=24c89f93817dce2de43bbcaa631c3d7367699778;f=index.html>Older posts</a>
27 </td></tr></table>
28 <br>
29 <div style="text-align:right;">
30 <a href="dscho.git?a=blob_plain;hb=blog;f=blog.rss"
31 title="Subscribe to my RSS feed"
32 class="rss" rel="nofollow"
33 style="background-color:orange;text-decoration:none;color:white;font-family:sans-serif;">RSS</a>
34 </div>
35 <br>
36 <table width=400px bgcolor=#e0e0e0 border=0>
37 <tr><th>About this blog:</th></tr>
38 <tr><td>
39 <p>It is an active <a href=http://repo.or.cz/w/git/dscho.git?a=blob_plain;f=index.html;hb=5f002cab57a837125a8f901bcd1f3c1477bc3119>abuse</a> of <a href=http://repo.or.cz/>repo.or.cz</a>,
40 letting gitweb unpack the objects in the current tip of the branch <i>blog</i>,
41 including the images and the RSS feed.
42 </p><p>
43 Publishing means running a script that collects the posts, turns them into
44 HTML, makes sure all the images are checked in, and pushes the result.
45 </p><p>
46 This blog also serves to grace the world with Dscho's random thoughts on and
47 around Git.
48 </p>
49 </td></tr></table>
50 <br>
51 <table width=400px bgcolor=#e0e0e0 border=0>
52 <tr><th>Links:</th></tr>
53 <tr><td>
54 <ul>
55 <li> <a href=http://git-scm.com/>Git's homepage</a>
56 <li> <a href=http://gitster.livejournal.com/>Junio's blog</a>
57 <li> <a href=http://www.spearce.org/>Shawn's blog</a> seems to be sitting
58 idle ever since he started working for Google...
59 <li> <a href=http://torvalds-family.blogspot.com/>Linus' blog</a> does not
60 talk much about Git...
61 <li> Scott Chacon's <a href=http://whygitisbetterthanx.com/>Why Git is better
62 than X</a> site
63 <li> <a href=http://vilain.net/>The blog of mugwump</a>
64 <li> <a href=http://merlyn.vox.com/>Merlyn's blog</a>
65 <li> <a href=http://blogs.gnome.org/newren/>Elijah Newren</a> chose the
66 same path as Cogito, offering an alternative porcelain (an approach
67 that is doomed in my opinion)
68 <li> <a href=http://msysgit.googlecode.com/>The msysGit project</a>, a (mostly)
69 failed experiment to lure the many Windows developers out there to
70 contribute to Open Source for a change.
71 </ul>
72 </td></tr></table>
73 <br>
74 <table width=400px bgcolor=#e0e0e0 border=0>
75 <tr><th>Google Ads:</th></tr>
76 <tr><td>
77 <script type="text/javascript"><!--
78 google_ad_client = "pub-5106407705643819";
79 /* 300x250, created 1/22/09 */
80 google_ad_slot = "6468207338";
81 google_ad_width = 300;
82 google_ad_height = 250;
83 //-->
84 </script>
85 <script type="text/javascript"
86 src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
87 </script>
88 </td></tr></table>
89 </div>
90 <h6>Friday, 19th of June, Anno Domini MMIX, at the hour of the Monkey</h6>
91 <a name=1245419588>
92 <h2>The GraphGUI project</h2>
94 <p>
95 </p><p>
96 After a few unfortunate delays (and some fortunate ones, just not for us), the
97 GraphGUI project finally takes off. A quick first glance:
98 </p><p>
99 <center><img src=dscho.git?a=blob_plain;hb=c33212b23b2b3e45c14403efe82cabb1cd53f6e3;f=basic-gui.jpg basic-gui.jpg></center>
100 </p><p>
101 The delays were a bit unnerving, but the student is really bright and still
102 has the chance to pull the project off.
103 </p><p>
104 Next plans are to show text, too, to invent a rudimentary layout engine that
105 can be adjusted manually (this is in contrast to <i>gitk</i> or <i>log --graph</i>).
106 </p><p>
107 After that, integration into JGit (this probably triggered the eGit/JGit
108 split).
109 </p><p>
110 And then we'll go wild!
111 </p>
112 <h6>Friday, 15th of May, Anno Domini MMIX, at the hour of the Dog</h6>
113 <a name=1242408298>
114 <h2>Wasting way too much time on msysGit</h2>
117 </p><p>
118 I recently got into the bad habit of spending a large amount of my waking
119 hours working on msysGit, more than is really healthy for me.
120 </p><p>
121 For example, I spent the whole morning -- when I should have worked on a
122 very important day-job project -- on trying to fix issue 258, where
123 <i>git web--browse</i> does not work as expected because of quoting issues
124 with cmd.exe.
125 </p><p>
126 This is reducing my Git time budget to negative numbers, so much so that I
127 cannot even work on Git projects that I actually like, such as <i>jgit diff</i>
128 or <i>git rebase -i -p</i>, or at least projects I felt obliged to continue
129 to work on, such as <i>git notes</i>.
130 </p><p>
131 Now, some people who tried to teach me some time management strongly
132 criticized me for ignoring their lessons, and unfortunately, I have to agree.
133 </p><p>
134 The problem is that I would <u>hate</u> to see msysGit fall to the same state it
135 was after I stopped working on it last year. I started it, and I would like
136 it to grow, but too few people took care of the issue tracker, too few tried
137 to debug their problems themselves, too few submitted fixes.
138 </p><p>
139 I note, though, that there is a positive trend. But being the impatient person
140 I am ("2 seconds is my attention span") I tend to want the trend to be more
141 impressive.
142 </p><p>
143 Anyway, no work on msysGit for at least 4 days, that's what the doctor (me)
144 said...
145 </p>
146 <h6>Monday, 11th of May, Anno Domini MMIX, at the hour of the Rat</h6>
147 <a name=1241995759>
148 <h2>Working on jgit diff</h2>
151 </p><p>
152 Shawn did so many useful things that I use on a daily basis that I felt really
153 awful when I realized just how <u>long</u> I had promised to clean up that diff
154 implementation I wrote for JGit.
155 </p><p>
156 Alas, it appears that the thing turned out to be almost a complete rewrite, as
157 the original implementation walked the edit graph in a rather inefficient way.
158 </p><p>
159 A little background: Myers' algorithm to generate "an edit script" works on
160 the <i>edit graph</i>: imagine you have all lines of file <i>A</i> as columns and
161 all lines of file <i>B</i> as rows, then the <i>edit graph</i> is a connection of
162 the upper left corner to the lower right corner, containing only horizontal,
163 vertical or diagonal elements, where diagonal elements are only allowed when
164 the lines of both files agree at that point:
165 </p><p>
166 <pre>
167 H E L L O , W O R L D
168 ----
174 --------
175 </pre>
176 </p><p>
177 The <i>shortest</i> edit path minimizes the number of non-diagonal elements.
178 </p><p>
179 Myers' idea is to develop forward and backward paths at the same time
180 (increasing the number of non-diagonal elements uniformly), storing
181 only the latest end points. Once the paths meet, divide and conquer.
182 </p><p>
183 In theory, it would be quicker to store <u>all</u> end points and then just
184 reconstruct the shortest paths, alas, this takes way too much memory.
185 </p><p>
186 My first implementation did not remember start or end of the non-diagonal
187 parts, and had to recurse way more often than really necessary (in the end,
188 we will order the non-diagonal parts into horizontal and vertical parts
189 anyway, so start and end are sufficient).
190 </p><p>
191 The current progress can be seen <a href=http://repo.or.cz/w/egit/dscho.git/>
192 here</a>.
193 </p>
194 <h6>Friday, 17th of April, Anno Domini MMIX, at the hour of the Monkey</h6>
195 <a name=1239975597>
196 <h2>No time for Git</h2>
199 </p><p>
200 It is a shame, but most of my Git time budget is taken by msysGit these
201 days.
202 </p><p>
203 But at least msysGit is moving again; I'll probably write a Herald about
205 </p>
206 <h6>Monday, 6th of April, Anno Domini MMIX, at the hour of the Rat</h6>
207 <a name=1238970571>
208 <h2>How to recover from a hackathon</h2>
211 </p><p>
212 Phew, 2 crazy and fantastic weeks are behind me. But it takes its toll:
213 a weekend I was more offline than online.
214 </p><p>
215 Things that are important now: relax. sleep. take a walk. learn to sleep
216 more than 4 hours a night again. learn to watch a movie without thinking
217 about code. go for a run.
218 </p><p>
219 And after recovering, back to the rebase-i-p branch!
220 </p>
221 <h6>Monday, 9th of March, Anno Domini MMIX, at the hour of the Rat</h6>
222 <a name=1236554268>
223 <h2>So, what is missing from my <i>rebase-i-p</i> branch?</h2>
226 </p><p>
227 I regularly use <i>rebase -i -p</i> these days, to update my personal Git
228 tree (which used to be <i>my-next</i>).
229 </p><p>
230 There are a few things missing before I can start assembling a patch
231 series for submission:
232 </p><p>
233 <ul>
234 <li>I need to handle the commit parents which are outside of the rebased
235 ones properly. In other words, when a commit is picked whose parent is
236 not rebased, it needs to be rebased onto $ONTO.
237 <li>The patch which uses patch-id to generate DROPPED directly also tries to
238 consolidate the handling of DROPPED commits by putting them into REWRITTEN
239 instead of DROPPED, but that breaks the tests. So, this patch needs to be
240 split.
241 <li>I want to introduce one more command, <i>rephrase</i>, which allows you to
242 modify the commit message, and nothing more, and <i>halt</i>, which does the
243 same as <i>edit</i> without <i>pick</i>. Then there needs to be a new test script
244 for those commands, and this will be an early patch series.
245 <li>Time. I need time, desperately. If my day job was not as exciting as it
246 is, I would have more time for Git. As it is, I have to budget my time so
247 that I get anything done at all.
248 </ul>
249 </p><p>
250 These issues have been postponed due to Steffen taking a well-deserved
251 vacation, which means that I have to act as msysGit maintainer again.
252 </p><p>
253 And this coming week, I will have other things to do in all likeliness, so
254 that I expect to be able to submit a <i>rebase -i -p</i> patch series only next
255 week. If not then, due to a heavy workload, it will be postponed to early
256 April.
257 </p><p>
258 Oh well, the joys of being excited by several competing projects! &#x263a;
259 </p>
260 <h6>Sunday, 8th of March, Anno Domini MMIX, at the hour of the Tiger</h6>
261 <a name=1236479389>
262 <h2>New Git for Windows version</h2>
265 </p><p>
266 Phew. That was quite a day, almost exclusively spent on finishing that
267 installer. The worst part: updating GCC seemed not to be such a good idea
268 after all...
269 </p><p>
270 For Windows, we need to use the printf format <i>%I64u</i> (which is
271 non-standard, in the common way of Microsoft) if you want to print 64-bit
272 wide unsigned numbers. The rest of the world accepts the standard <i>%llu</i>.
273 </p><p>
274 After upgrading to the new GCC, a lot of warnings appeared, complaining
275 about <i>%I64u</i>. The warnings went away when I replaced the format with
276 <i>%llu</i>.
277 </p><p>
278 Being the naive I am, I mistook that for a sign that we could finally go
279 more standards-compliant.
280 </p><p>
281 However, it only means that we have to live with the warnings for now, as
282 the C runtime provided on Windows still strongly disagrees with standards
283 (and it has to continue to do so, lest it break existing programs).
284 </p><p>
285 Sigh.
286 </p><p>
287 At least I have the feeling that I caught the most important bugs before
288 releasing.
289 </p>
290 <h6>Friday, 20th of February, Anno Domini MMIX, at the hour of the Buffalo</h6>
291 <a name=1235092615>
292 <h2>Code reviews</h2>
295 </p><p>
296 It has been said that reviewing patches is a most thankless job. As I really
297 like the elegance of Git's source code, and care a lot about it, I did not
298 think that it was thankless, just a little bit tedious (especially when the
299 patch authors mistake criticism for personal attacks).
300 </p><p>
301 Usually, I am pretty good at ignoring insults as responses to my comments;
302 after all, I have a lot more enjoyable things to do than to spend time talking
303 to a guy who shows how wise he is when he thinks that I criticize him
304 <u>personally</u> when I just try to enhance his work, by offering a little bit of
305 my knowledge.
306 </p><p>
307 However, in the last days, three people really seemed to want to insult me,
308 to make me go away, to stop the fun I have with Git.
309 </p><p>
310 And they almost succeeded.
311 </p><p>
312 So I guess it is time to reassess my priorities, and maybe stop reviewing
313 Git patches altogether.
314 </p>
315 <h6>Thursday, 12th of February, Anno Domini MMIX, at the hour of the Tiger</h6>
316 <a name=1234409395>
317 <h2>Interactive <i>rebase</i> just learnt a new command: <i>topic</i></h2>
320 </p><p>
321 Today I am pretty pleased with myself. Two projects at my day job got a real
322 boost, and I implemented a shortcut that avoids the ugly 'bookmark' statement
323 in rebase scripts most of the time.
324 </p><p>
325 A typical rebase script, generated by <i>git rebase -i -p $COMMIT</i> will look
326 something like this:
327 </p><p>
328 <table
329 border=1 bgcolor=black>
330 <tr><td bgcolor=lightblue colspan=3>
331 <pre> </pre>
332 </td></tr>
333 <tr><td>
334 <table cellspacing=5 border=0
335 style="color:white;">
336 <tr><td>
337 <pre>
338 pick 1234567 My first commit
339 topic begin super-cool-feature
340 pick 2345678 The super cool feature
341 pick 3456789 Documentation for the super cool feature
342 topic end super-cool-feature
343 </pre>
344 </td></tr>
345 </table>
346 </td></tr>
347 </table>
348 </p><p>
349 The result will be a merge commit at the HEAD whose first parent is
350 "My first commit", whose second parent is "Documentation for the super
351 cool feature" and whose commit message is "Merge branch 'super-cool-feature'".
352 </p><p>
353 Side note: internally, <i>topic begin $NAME [at $COMMIT]</i> will be handled as if
354 you wrote <i>bookmark merge-parent-of-$NAME; goto $COMMIT</i>, and
355 <i>topic end $NAME [$MESSAGE]</i> will be handled as if you wrote
356 <i>bookmark $NAME; goto merge-parent-of-$NAME; merge parents $NAME [original $MARK Merge branch '$NAME']</i>.
357 </p><p>
358 Of course, being more concise, the 'topic' statement is not only nicer to the
359 eye, but also less error-prone.
360 </p><p>
361 And hopefully many people will agree with me that this rebase script is pretty
362 intuitive.
363 </p>
364 <h6>Wednesday, 11th of February, Anno Domini MMIX, at the hour of the Tiger</h6>
365 <a name=1234320806>
366 <h2>Thunderbird, oh Thunderbird, you always make my small brain hurt</h2>
369 </p><p>
370 There was a lengthy discussion on the Git mailing list about using Thunderbird,
371 a not quite unpopular mailing program, to send inline patches.
372 </p><p>
373 It is really kind of sad that the Thunderbird developers do not see how
374 stubbornly they offend quite a number of people and scare them away from their
375 program. After all, you should try to be liberal in what you accept and strict
376 in what you emit. No, that does not mean that you should force others to
377 switch their mailers because you strictly adher to your philosophy in what you
378 emit, ignoring the rest of the world.
379 </p><p>
380 In any case, I am not affected (as long as I do not get mails from a poor soul
381 stuck with Thunderbird).
382 </p><p>
383 But I was a bit mean to that Thunderbird guy I dragged into the discussion, and
384 he seems really offended.
385 </p><p>
386 So I thought I'd give him a real reason to feel offended: I'll just do his work:
387 </p><p>
388 http://repo.or.cz/w/UnFlowedThunderbird.git
389 </p><p>
390 It took my free time of two days, being not a Thunderbird developer myself.
391 Hopefully it works, and hopefully some people will feel really ashamed now.
392 </p>
393 </div>
394 </body>
395 </html>