{"thread":{"id":"5636","subject":"[PATCH] gitweb: fix display of trees via PATH_INFO.","startedAt":"2006-09-21T07:48:21Z","lastAt":"2006-09-21T08:56:37Z","messageCount":2,"participants":["Martin Waitz","Jakub Narebski"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"27348","messageId":"20060921074821.GG31940@admingilde.org","threadId":"5636","inReplyTo":null,"subject":"[PATCH] gitweb: fix display of trees via PATH_INFO.","fromName":"Martin Waitz","fromEmail":"tali@admingilde.org","sentAt":"2006-09-21T07:48:21Z","receivedAt":"2006-09-21T07:48:21Z","isPatch":true,"sender":{"key":"tali@admingilde.org","avatar":"https://gravatar.com/avatar/3f89b03eee362187effabe257898735b475673a12265c398ea9161259ae91553?d=mp&s=160"},"body":"When adding a / to the URL, git should display the corresponding\ntree object, but it has to remove the / first.\n\nSigned-off-by: Martin Waitz <tali@admingilde.org>\n---\n gitweb/gitweb.perl |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl\nindex baadbe7..ea57717 100755\n--- a/gitweb/gitweb.perl\n+++ b/gitweb/gitweb.perl\n@@ -300,6 +300,7 @@ sub evaluate_path_info {\n \t\t$pathname =~ s,^/+,,;\n \t\tif (!$pathname || substr($pathname, -1) eq \"/\") {\n \t\t\t$action  ||= \"tree\";\n+\t\t\t$pathname =~ s,/$,,;\n \t\t} else {\n \t\t\t$action  ||= \"blob_plain\";\n \t\t}\n-- \n1.4.2.gb8b6b\n\n-- \nMartin Waitz\n"},{"id":"27350","messageId":"eetk3v$22n$2@sea.gmane.org","threadId":"5636","inReplyTo":"20060921074821.GG31940@admingilde.org","subject":"Re: [PATCH] gitweb: fix display of trees via PATH_INFO.","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-09-21T08:56:37Z","receivedAt":"2006-09-21T08:56:37Z","isPatch":true,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Martin Waitz wrote:\n\n> When adding a / to the URL, git should display the corresponding\n> tree object, but it has to remove the / first.\n\nHmm... I thought that gitweb works just fine with file_name ('f') parameter\nwith trailing '/'... I guessed wrong.\n\nBy the way, we should fix error when we try to \"tree\" display blob, or\n\"blob\" display tree.\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"}]}