From - Sat Aug 9 22:59:16 2008 X-Mozilla-Status: 0001 X-Mozilla-Status2: 00000000 Return-Path: lewiemann+caf_=lewiemann=vassar.edu@gmail.com Received: from zimmta01.vassar.edu (LHLO zimmta01.vassar.edu) (143.229.1.149) by zimmbox01.vassar.edu with LMTP; Sun, 3 Aug 2008 22:13:45 -0400 (EDT) Received: from ironport02.vassar.edu (ironport02.vassar.edu [143.229.1.219]) by zimmta01.vassar.edu (Postfix) with ESMTP id 914BA41C828 for ; Sun, 3 Aug 2008 22:13:45 -0400 (EDT) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AnsBAOMBlkhIDtyejmdsb2JhbACQUDE+AQEBAQkDCgcPnBo X-IronPort-AV: E=Sophos;i="4.31,302,1215403200"; d="diff'?scan'208";a="70523409" X-SenderBase-Score: 4.2 Received: from fg-out-1718.google.com ([72.14.220.158]) by ironport02.vassar.edu with ESMTP; 03 Aug 2008 22:13:44 -0400 Received: by fg-out-1718.google.com with SMTP id 16so930426fgg.44 for ; Sun, 03 Aug 2008 19:13:44 -0700 (PDT) Received: by 10.86.26.1 with SMTP id 1mr9902826fgz.35.1217816024528; Sun, 03 Aug 2008 19:13:44 -0700 (PDT) X-Forwarded-To: lewiemann@vassar.edu X-Forwarded-For: lewiemann@gmail.com lewiemann@vassar.edu Delivered-To: lewiemann@gmail.com Received: by 10.86.31.13 with SMTP id e13cs124502fge; Sun, 3 Aug 2008 19:13:44 -0700 (PDT) Received: by 10.65.96.17 with SMTP id y17mr1700313qbl.16.1217816014345; Sun, 03 Aug 2008 19:13:34 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by mx.google.com with ESMTP id s35si11340609qbs.13.2008.08.03.19.12.49; Sun, 03 Aug 2008 19:13:34 -0700 (PDT) Received-SPF: pass (google.com: domain of git-owner@vger.kernel.org designates 209.132.176.167 as permitted sender) client-ip=209.132.176.167; Authentication-Results: mx.google.com; spf=pass (google.com: domain of git-owner@vger.kernel.org designates 209.132.176.167 as permitted sender) smtp.mail=git-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754023AbYHDCMm (ORCPT + 99 others); Sun, 3 Aug 2008 22:12:42 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753977AbYHDCMl (ORCPT ); Sun, 3 Aug 2008 22:12:41 -0400 Received: from c-67-188-226-86.hsd1.ca.comcast.net ([67.188.226.86]:53308 "EHLO localhost.localdomain" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754023AbYHDCMj (ORCPT ); Sun, 3 Aug 2008 22:12:39 -0400 X-Greylist: delayed 695 seconds by postgrey-1.27 at vger.kernel.org; Sun, 03 Aug 2008 22:12:38 EDT Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by localhost.localdomain (8.14.2/8.14.2) with ESMTP id m7420JkZ011364; Sun, 3 Aug 2008 19:00:19 -0700 Received: (from warthog9@localhost) by localhost.localdomain (8.14.2/8.14.2/Submit) id m7420JGh011363; Sun, 3 Aug 2008 19:00:19 -0700 X-Authentication-Warning: localhost.localdomain: warthog9 set sender to warthog19@eaglescrag.net using -f From: warthog19@eaglescrag.net To: git@vger.kernel.org Cc: "John 'Warthog9' Hawley" , "John 'Warthog9' Hawley" Subject: [PATCH 1/1] Add "git" link to the end of project line on the project_list page. Date: Sun, 3 Aug 2008 19:00:17 -0700 Message-Id: <1217815217-11329-2-git-send-email-warthog19@eaglescrag.net> X-Mailer: git-send-email 1.5.4.1 In-Reply-To: <1217815217-11329-1-git-send-email-warthog19@eaglescrag.net> References: <1217815217-11329-1-git-send-email-warthog19@eaglescrag.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------1.5.4.1" Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: John 'Warthog9' Hawley This is a multi-part message in MIME format. --------------1.5.4.1 Content-Type: text/plain; charset=UTF-8; format=fixed Content-Transfer-Encoding: 8bit This makes the assumption that all repositories are available from a unified location. Using .git/cloneurl is actually a problem as that can define multiple URLs to clone from, and we are seeking a single unified URL for now. Signed-off-by: John 'Warthog9' Hawley --- gitweb/gitweb.perl | 15 +++++++++++++-- 1 files changed, 13 insertions(+), 2 deletions(-) --------------1.5.4.1 Content-Type: text/x-patch; name="07ce8f81cc06027c9c166cf316238d7a4af17162.diff" Content-Transfer-Encoding: 8bit Content-Disposition: inline; filename="07ce8f81cc06027c9c166cf316238d7a4af17162.diff" diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 90cd99b..c33f4ed 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -108,6 +108,14 @@ our $mimetypes_file = undef; # could be even 'utf-8' for the old behavior) our $fallback_encoding = 'latin1'; +# enable / disable a final link on the project list page +# that will be the location of that actuall git url +# it will output this in the format: +# git://hostname/path/to/tree.git +# disabled = blank or undef +# enable = url to prefix before filling in the trailing path to the git repo +our $projectlist_gitlinkurl = undef; + # rename detection options for git-diff and git-diff-tree # - default is '-M', with the cost proportional to # (number of removed files) * (number of new files). @@ -3661,8 +3669,11 @@ sub git_project_list_body { $cgi->a({-href => href(project=>$pr->{'path'}, action=>"shortlog")}, "shortlog") . " | " . $cgi->a({-href => href(project=>$pr->{'path'}, action=>"log")}, "log") . " | " . $cgi->a({-href => href(project=>$pr->{'path'}, action=>"tree")}, "tree") . - ($pr->{'forks'} ? " | " . $cgi->a({-href => href(project=>$pr->{'path'}, action=>"forks")}, "forks") : '') . - "\n" . + ($pr->{'forks'} ? " | " . $cgi->a({-href => href(project=>$pr->{'path'}, action=>"forks")}, "forks") : ''); + if( $projectlist_gitlinkurl != undef && $projectlist_gitlinkurl ne "" ){ + print " | ". $cgi->a({-href => "git://projectlist_gitlinkurl/".esc_html($pr->{'path'})}, "git"); + } + print "\n" . "\n"; } if (defined $extra) { --------------1.5.4.1-- -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html