{"thread":{"id":"32019","subject":"git log --graph --oneline - false parent-child visualization","startedAt":"2012-11-05T12:57:43Z","lastAt":"2012-11-05T14:17:33Z","messageCount":2,"participants":["martyone","Michael J Gruber"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"202540","messageId":"CAMn6BBaeWfwa_mAyTBFOmFYs0GwUauzqZZP+NWM=8f0_hKDz3Q@mail.gmail.com","threadId":"32019","inReplyTo":null,"subject":"git log --graph --oneline - false parent-child visualization","fromName":"martyone","fromEmail":"martyone@ubedi.net","sentAt":"2012-11-05T12:57:43Z","receivedAt":"2012-11-05T12:57:43Z","isPatch":false,"sender":{"key":"martyone@ubedi.net","avatar":null},"body":"Hello,\n\nthe combination of --graph and --oneline sometimes produces output\nwhich is -- at least for me -- not clear about parent-child relation\nbetween commits. I noticed it when using with --simplify-by-decoration\nswitch but it should not be specific to the use of this switch.\n\nSee this example output (git version 1.7.11.3)\n\n| | | * eead15f (origin/branchA) Lorem ipsum dolor sit amet\n| |_|/\n|/| |\n| | | * 8da3b9f (origin/branchB) Consectetur adipisicing elit\n| | |/\n| | | * c4d6b9a (origin/branchC) Sed do eiusmod tempor incididunt ut labore\n| | | * d623246 (origin/branchD) Ut enim ad minim veniam\n| | |/\n| | | * 458d305 (origin/btanchE) Quis nostrud exercitation ullamco laboris\n| | |/\n\nHere it seems commit c4d6b9a is based on d623246. But when the format\nis more-than-oneline (or when checked with gitk), it is clear there is\nno relation between commits c4d6b9a and d623246.\n\n| | | * commit eead15f (origin/branchA)\n| |_|/  Author: John Doe <john.doe@example.net>\n|/| |\n| | |       Lorem ipsum dolor sit amet\n| | |\n| | | * commit 8da3b9f (origin/branchB)\n| | |/  Author: John Doe <john.doe@example.net>\n| | |\n| | |       Consectetur adipisicing elit\n| | |\n| | | * commit c4d6b9a (origin/branchC)\n| | |   Author: John Doe <john.doe@example.net>\n| | |\n| | |       Sed do eiusmod tempor incididunt ut labore\n| | |\n| | | * commit d623246 (origin/branchD)\n| | |/  Author: John Doe <john.doe@example.net>\n| | |\n| | |       Ut enim ad minim veniam\n| | |\n| | | * commit 458d305 (origin/branchE)\n| | |/  Author: John Doe <john.doe@example.net>\n| | |\n| | |       Quis nostrud exercitation ullamco laboris\n| | |\n\nCorrect output produced with --oneline switch should output an extra\nnewline when commit has no parent listed:\n\n| | | * eead15f (origin/branchA) Lorem ipsum dolor sit amet\n| |_|/\n|/| |\n| | | * 8da3b9f (origin/branchB) Consectetur adipisicing elit\n| | |/\n| | | * c4d6b9a (origin/branchC) Sed do eiusmod tempor incididunt ut labore\n| | |\n| | | * d623246 (origin/branchD) Ut enim ad minim veniam\n| | |/\n| | | * 458d305 (origin/btanchE) Quis nostrud exercitation ullamco laboris\n| | |/\n\nBest Regards,\nMartin\n"},{"id":"202544","messageId":"5097CA7D.50301@drmicha.warpmail.net","threadId":"32019","inReplyTo":"CAMn6BBaeWfwa_mAyTBFOmFYs0GwUauzqZZP+NWM=8f0_hKDz3Q@mail.gmail.com","subject":"Re: git log --graph --oneline - false parent-child visualization","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2012-11-05T14:17:33Z","receivedAt":"2012-11-05T14:17:33Z","isPatch":false,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"martyone venit, vidit, dixit 05.11.2012 13:57:\n> Hello,\n> \n> the combination of --graph and --oneline sometimes produces output\n> which is -- at least for me -- not clear about parent-child relation\n> between commits. I noticed it when using with --simplify-by-decoration\n> switch but it should not be specific to the use of this switch.\n> \n> See this example output (git version 1.7.11.3)\n> \n> | | | * eead15f (origin/branchA) Lorem ipsum dolor sit amet\n> | |_|/\n> |/| |\n> | | | * 8da3b9f (origin/branchB) Consectetur adipisicing elit\n> | | |/\n> | | | * c4d6b9a (origin/branchC) Sed do eiusmod tempor incididunt ut labore\n> | | | * d623246 (origin/branchD) Ut enim ad minim veniam\n> | | |/\n> | | | * 458d305 (origin/btanchE) Quis nostrud exercitation ullamco laboris\n> | | |/\n> \n> Here it seems commit c4d6b9a is based on d623246. But when the format\n> is more-than-oneline (or when checked with gitk), it is clear there is\n> no relation between commits c4d6b9a and d623246.\n> \n> | | | * commit eead15f (origin/branchA)\n> | |_|/  Author: John Doe <john.doe@example.net>\n> |/| |\n> | | |       Lorem ipsum dolor sit amet\n> | | |\n> | | | * commit 8da3b9f (origin/branchB)\n> | | |/  Author: John Doe <john.doe@example.net>\n> | | |\n> | | |       Consectetur adipisicing elit\n> | | |\n> | | | * commit c4d6b9a (origin/branchC)\n> | | |   Author: John Doe <john.doe@example.net>\n> | | |\n> | | |       Sed do eiusmod tempor incididunt ut labore\n> | | |\n> | | | * commit d623246 (origin/branchD)\n> | | |/  Author: John Doe <john.doe@example.net>\n> | | |\n> | | |       Ut enim ad minim veniam\n> | | |\n> | | | * commit 458d305 (origin/branchE)\n> | | |/  Author: John Doe <john.doe@example.net>\n> | | |\n> | | |       Quis nostrud exercitation ullamco laboris\n> | | |\n> \n> Correct output produced with --oneline switch should output an extra\n> newline when commit has no parent listed:\n> \n> | | | * eead15f (origin/branchA) Lorem ipsum dolor sit amet\n> | |_|/\n> |/| |\n> | | | * 8da3b9f (origin/branchB) Consectetur adipisicing elit\n> | | |/\n> | | | * c4d6b9a (origin/branchC) Sed do eiusmod tempor incididunt ut labore\n> | | |\n> | | | * d623246 (origin/branchD) Ut enim ad minim veniam\n> | | |/\n> | | | * 458d305 (origin/btanchE) Quis nostrud exercitation ullamco laboris\n> | | |/\n> \n> Best Regards,\n> Martin\n> \n\nYes, you have the same problem when you simply have two disjoint\nbranches: They're listed \"concatenated\". The problem is that log --graph\nuses the single symbol \"*\" for many different cases, independent of the\nnumber of ingoing or outgoing lines. There are two solutions:\n\n- use more spacing\n- use more symbols (like tig does) and stay compact\n\nFeel free to experiment ;)\n\nMichael\n"}]}