{"thread":{"id":"43201","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","startedAt":"2006-10-26T16:43:10Z","lastAt":"2006-10-27T01:47:40Z","messageCount":6,"participants":["Junio C Hamano","Petr Baudis","Jakub Narebski","Luben Tuikov"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"298497","messageId":"200610261843.10529.jnareb@gmail.com","threadId":"43201","inReplyTo":"200610261813.12567.jnareb@gmail.com","subject":"[PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-10-26T16:43:10Z","receivedAt":"2006-10-26T16:43:10Z","isPatch":true,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Signed-off-by: Jakub Narebski <jnareb@gmail.com>\n---\nThis amend fixes regression which caused signoff lines\nto be not highlighted as such.\n\n gitweb/gitweb.css  |   16 ++++++++++++++--\n gitweb/gitweb.perl |   18 ++++++++++--------\n 2 files changed, 24 insertions(+), 10 deletions(-)\n\ndiff --git a/gitweb/gitweb.css b/gitweb/gitweb.css\nindex 0eda982..83d900d 100644\n--- a/gitweb/gitweb.css\n+++ b/gitweb/gitweb.css\n@@ -100,7 +100,7 @@ span.age {\n \tfont-style: italic;\n }\n \n-div.page_body span.signoff {\n+span.signoff {\n \tcolor: #888888;\n }\n \n@@ -114,7 +114,7 @@ div.log_link {\n \twidth: 136px;\n }\n \n-div.list_head {\n+div.diff_tree_head {\n \tpadding: 6px 8px 4px;\n \tborder: solid #d9d8d1;\n \tborder-width: 1px 0px 0px;\n@@ -128,6 +128,18 @@ div.author_date {\n \tfont-style: italic;\n }\n \n+div.commitdiff_log {\n+\tpadding: 8px;\n+\tborder: solid #d9d8d1;\n+\tborder-width: 0px 0px 1px 0px;\n+}\n+\n+div.patchset {\n+\tpadding-top: 8px;\n+\tborder: solid #d9d8d1;\n+\tborder-width: 1px 0px 0px 0px;\n+}\n+\n a.list {\n \ttext-decoration: none;\n \tcolor: #000000;\ndiff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl\nindex 0d2ea72..044a47d 100755\n--- a/gitweb/gitweb.perl\n+++ b/gitweb/gitweb.perl\n@@ -1844,11 +1844,11 @@ sub git_print_tree_entry {\n sub git_difftree_body {\n \tmy ($difftree, $hash, $parent) = @_;\n \n-\tprint \"<div class=\\\"list_head\\\">\\n\";\n \tif ($#{$difftree} > 10) {\n+\t\tprint \"<div class=\\\"list_head\\\">\\n\";\n \t\tprint(($#{$difftree} + 1) . \" files changed:\\n\");\n+\t\tprint \"</div>\\n\";\n \t}\n-\tprint \"</div>\\n\";\n \n \tprint \"<table class=\\\"diff_tree\\\">\\n\";\n \tmy $alternate = 1;\n@@ -2053,9 +2053,9 @@ sub git_patchset_body {\n \t\t\t}\n \t\t\t$patch_idx++;\n \n-\t\t\t# for now, no extended header, hence we skip empty patches\n-\t\t\t# companion to\tnext LINE if $in_header;\n-\t\t\tif ($diffinfo->{'from_id'} eq $diffinfo->{'to_id'}) { # no change\n+\t\t\t# for now we skip empty patches\n+\t\t\tif ($diffinfo->{'from_id'} eq $diffinfo->{'to_id'}) {\n+\t\t\t\t# no change, empty patch\n \t\t\t\t$in_header = 1;\n \t\t\t\tnext LINE;\n \t\t\t}\n@@ -3486,13 +3486,15 @@ sub git_commitdiff {\n \t\tgit_print_page_nav('commitdiff','', $hash,$co{'tree'},$hash, $formats_nav);\n \t\tgit_print_header_div('commit', esc_html($co{'title'}) . $ref, $hash);\n \t\tgit_print_authorship(\\%co);\n-\t\tprint \"<div class=\\\"page_body\\\">\\n\";\n+\n \t\tif (@{$co{'comment'}} > 1) {\n-\t\t\tprint \"<div class=\\\"log\\\">\\n\";\n+\t\t\tprint \"<div class=\\\"commitdiff_log\\\">\\n\";\n \t\t\tgit_print_log($co{'comment'}, -final_empty_line=> 1, -remove_title => 1);\n-\t\t\tprint \"</div>\\n\"; # class=\"log\"\n+\t\t\tprint \"</div>\\n\"; # class=\"commitdiff_log\"\n \t\t}\n \n+\t\tprint \"<div class=\\\"page_body\\\">\\n\";\n+\n \t} elsif ($format eq 'plain') {\n \t\tmy $refs = git_get_references(\"tags\");\n \t\tmy $tagname = git_get_rev_name_tags($hash);\n-- \n1.4.3.3\n"},{"id":"298296","messageId":"20061026233439.37073.qmail@web31811.mail.mud.yahoo.com","threadId":"43201","inReplyTo":"200610261843.10529.jnareb@gmail.com","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Luben Tuikov","fromEmail":"ltuikov@yahoo.com","sentAt":"2006-10-26T23:34:39Z","receivedAt":"2006-10-26T23:34:39Z","isPatch":true,"sender":{"key":"ltuikov@yahoo.com","avatar":null},"body":"Can you please explain what both patches actually do?\n\n\"slight visual improvements to commitdiff view\" leaves\nmuch, _much_ to be desired and is hardly a commit message\nsuitable to live in git.git.\n\nPlease describe what you found objectionable, why, how\nyou decided to fix it and why you decided to fix it that way.\n\nThanks,\n   Luben\n"},{"id":"297286","messageId":"200610270150.40100.jnareb@gmail.com","threadId":"43201","inReplyTo":"20061026233439.37073.qmail@web31811.mail.mud.yahoo.com","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-10-26T23:50:39Z","receivedAt":"2006-10-26T23:50:39Z","isPatch":true,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Luben Tuikov wrote:\n> Can you please explain what both patches actually do?\n> \n> \"slight visual improvements to commitdiff view\" leaves\n> much, _much_ to be desired and is hardly a commit message\n> suitable to live in git.git.\n> \n> Please describe what you found objectionable, why, how\n> you decided to fix it and why you decided to fix it that way.\n\nAdding difftree/whatchanged output to commitdiff view was somewhat\nhasty, without taking care of details like separator between message \nbody and difftree, and separator between difftree and patchset.\n\nFirst, I have removed creating empty divs. The div with number of \nchanged files in git_difftree_body is added only if the message about \nnumber of changed files is displayed (above 10).\n\nSecond, I have moved commit message body in commitdiff outside \n\"page_body\" div, to be together with \"author_date\" div with authorship \ninfo. The name of class was changed from \"log\" to more informative \n\"commitdiff_log\". This required some changes and additions to CSS. Now \n\"commitdiff_log\" div is responsible for displaying line separatring it \nfrom \"page_body\".\n\nI have added not full line above \"patchset\" div (between patchet and \ndifftree). It is added by \"patchset\" div and separated by 8px padding.\n\n\nThose changes might wait for proper refactoring of gitweb CSS (having \nfor example 8px padding in one place only).\n-- \nJakub Narebski\n"},{"id":"298151","messageId":"780488.44315.qm@web31803.mail.mud.yahoo.com","threadId":"43201","inReplyTo":"200610270150.40100.jnareb@gmail.com","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Luben Tuikov","fromEmail":"ltuikov@yahoo.com","sentAt":"2006-10-27T00:39:14Z","receivedAt":"2006-10-27T00:39:14Z","isPatch":true,"sender":{"key":"ltuikov@yahoo.com","avatar":null},"body":"--- Jakub Narebski <jnareb@gmail.com> wrote:\n> First, I have removed creating empty divs. The div with number of \n> changed files in git_difftree_body is added only if the message about \n> number of changed files is displayed (above 10).\n> \n> Second, I have moved commit message body in commitdiff outside \n> \"page_body\" div, to be together with \"author_date\" div with authorship \n> info. The name of class was changed from \"log\" to more informative \n> \"commitdiff_log\". This required some changes and additions to CSS. Now \n> \"commitdiff_log\" div is responsible for displaying line separatring it \n> from \"page_body\".\n> \n> I have added not full line above \"patchset\" div (between patchet and \n> difftree). It is added by \"patchset\" div and separated by 8px padding.\n> \n> \n> Those changes might wait for proper refactoring of gitweb CSS (having \n> for example 8px padding in one place only).\n\nExcellent!  I'd like this explanation to be part of the\ncommit message if that patchset is committed to git.git.\n\n    Luben\n"},{"id":"294024","messageId":"7vu01qilg1.fsf@assigned-by-dhcp.cox.net","threadId":"43201","inReplyTo":"780488.44315.qm@web31803.mail.mud.yahoo.com","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-10-27T01:42:06Z","receivedAt":"2006-10-27T01:42:06Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Luben Tuikov <ltuikov@yahoo.com> writes:\n\n> --- Jakub Narebski <jnareb@gmail.com> wrote:\n> ...\n>> Those changes might wait for proper refactoring of gitweb CSS (having \n>> for example 8px padding in one place only).\n>\n> Excellent!  I'd like this explanation to be part of the\n> commit message if that patchset is committed to git.git.\n\nI'd like that kind of explanation with the patch in a single\nmessage when it is ready to be applied, too.\n\nI'll leave it up to you guys to decide if CSS refactoring should\ngo in first (I personally feel it probably is the case, in which\ncase this patch would need to be rebased I suspect).\n"},{"id":"296236","messageId":"20061027014740.GV20017@pasky.or.cz","threadId":"43201","inReplyTo":"7vu01qilg1.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH (amend)] gitweb: Slight visual improvements to commitdiff view","fromName":"Petr Baudis","fromEmail":"pasky@suse.cz","sentAt":"2006-10-27T01:47:40Z","receivedAt":"2006-10-27T01:47:40Z","isPatch":true,"sender":{"key":"pasky@ucw.cz","avatar":"https://avatars.githubusercontent.com/u/18439?v=4"},"body":"Dear diary, on Fri, Oct 27, 2006 at 03:42:06AM CEST, I got a letter\nwhere Junio C Hamano <junkio@cox.net> said that...\n> Luben Tuikov <ltuikov@yahoo.com> writes:\n> \n> > --- Jakub Narebski <jnareb@gmail.com> wrote:\n> > ...\n> >> Those changes might wait for proper refactoring of gitweb CSS (having \n> >> for example 8px padding in one place only).\n> >\n> > Excellent!  I'd like this explanation to be part of the\n> > commit message if that patchset is committed to git.git.\n> \n> I'd like that kind of explanation with the patch in a single\n> message when it is ready to be applied, too.\n> \n> I'll leave it up to you guys to decide if CSS refactoring should\n> go in first (I personally feel it probably is the case, in which\n> case this patch would need to be rebased I suspect).\n\nWe don't have any such patch, do we? So let anyone doing that patch take\nthis one into account and merge in whatever we have, I'd say.\n\n-- \n\t\t\t\tPetr \"Pasky\" Baudis\nStuff: http://pasky.or.cz/\n#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj\n$/=unpack('H*',$_);$_=`echo 16dio\\U$k\"SK$/SM$n\\EsN0p[lN*1\n"}]}