All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: git@vger.kernel.org
Subject: [PATCH 3/3 (take 2)] gitweb: Add link to "project_index" view to "project_list" page
Date: Fri, 15 Sep 2006 11:11:33 +0200	[thread overview]
Message-ID: <200609151111.33942.jnareb@gmail.com> (raw)
In-Reply-To: <200609150459.27708.jnareb@gmail.com>

Add link to "project_index" view as [TXT] beside link to "opml" view,
(which is marked by [OPML]) to "project_list" page.

While at it add alternate links for "opml" and "project_list" to HTML
header for "project_list" view.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
---
Corrected alternate links (dumb error while copy'n'paste).

 gitweb/gitweb.perl |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)

diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index e900713..3079531 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -1255,6 +1255,13 @@ EOF
 		printf('<link rel="alternate" title="%s log" '.
 		       'href="%s" type="application/rss+xml"/>'."\n",
 		       esc_param($project), href(action=>"rss"));
+	} else {
+		printf('<link rel="alternate" title="%s projects list" '.
+		       'href="%s" type="text/plain; charset=utf-8"/>'."\n",
+		       $site_name, href(project=>undef, action=>"project_index"));
+		printf('<link rel="alternate" title="%s projects logs" '.
+		       'href="%s" type="text/x-opml"/>'."\n",
+		       $site_name, href(project=>undef, action=>"opml"));
 	}
 	if (defined $favicon) {
 		print qq(<link rel="shortcut icon" href="$favicon" type="image/png"/>\n);
@@ -1309,7 +1316,9 @@ sub git_footer_html {
 		              -class => "rss_logo"}, "RSS") . "\n";
 	} else {
 		print $cgi->a({-href => href(project=>undef, action=>"opml"),
-		              -class => "rss_logo"}, "OPML") . "\n";
+		              -class => "rss_logo"}, "OPML") . " ";
+		print $cgi->a({-href => href(project=>undef, action=>"project_index"),
+		              -class => "rss_logo"}, "TXT") . "\n";
 	}
 	print "</div>\n" .
 	      "</body>\n" .
-- 
1.4.2

  reply	other threads:[~2006-09-15  9:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-15  2:53 [PATCH 0/3] Add git_project_index, improve href() Jakub Narebski
2006-09-15  2:56 ` [PATCH 1/3] gitweb: Add git_project_index for generating index.aux Jakub Narebski
2006-09-15  2:57 ` [PATCH 2/3] gitweb: Allow for href() to be used for projectless links Jakub Narebski
2006-09-15  6:17   ` Junio C Hamano
2006-09-15  7:21     ` Jakub Narebski
2006-09-15  2:59 ` [PATCH 3/3] gitweb: Add link to "project_index" view to "project_list" page Jakub Narebski
2006-09-15  9:11   ` Jakub Narebski [this message]
2006-09-15 17:30 ` [PATCH 2/3 (take 2)] gitweb: Allow for href() to be used for links without project param Jakub Narebski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200609151111.33942.jnareb@gmail.com \
    --to=jnareb@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.