From: Junio C Hamano Date: Thu, 10 May 2007 02:04:01 GMT Subject: Re: [PATCH] gitweb: choose appropriate view for file type if a= parameter missing. Message-ID: <7vvef1o2ni.fsf@assigned-by-dhcp.cox.net> In-Reply-To: <20070509221928.17244.qmail@f9729cdcdf57d1.315fe32.mid.smarden.org> Gerrit Pape writes: > See http://bugs.debian.org/410465 > > gitweb URLs use the a= parameter for the view to use on the given path, such > as "blob" or "tree". Currently, if a gitweb URL omits the a= parameter, > gitweb just shows the top-level repository summary, regardless of the path > given. gitweb could instead choose an appropriate view based on the file > type: blob for blobs (files), tree for trees (directories), and summary if no > path given (the URL included no f= parameter, or an empty f= parameter). > > Apart from making gitweb more robust and supporting URL editing more easily, > this change would aid the creation of shortcuts to git repositories using > simple substitution, such as: > http://example.org/git/?p=path/to/repo.git;hb=HEAD;f=%s > > - Josh Triplett > > Signed-off-by: Gerrit Pape I am not sure if this is a "good" feature or just "because we can" feature, but I am slightly in favor. I do not know about others. I'd however request a few changes to the proposed commit log message: * "See http://..." is not the primary information, but "see ... for further details"; please have it at the end, not at the beginning. * Was the patch authored by you, or Josh? If the former, what's his name doing here? Perhaps you wanted to say "Reported by Josh Triplett"?