[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#462934: PTS -- Please redirect automatically for packages.qa.debian.org/<binary-package>



On Mon, Jan 28, 2008 at 02:13:09PM +0100, Lucas Nussbaum wrote:
> On 28/01/08 at 17:16 +0530, Kumar Appaiah wrote:
> > Package: qa.debian.org
> > Severity: wishlist
> > User: qa.debian.org@packages.debian.org
> > Usertags: pts
> > 
> > Dear PTS maintainers,
> > 
> > Could you please consider redirecting to the QA page of the
> > appropriate source package automatically without the 10 second wait?
> > In my opinion, I don't think you would be causing many people trouble
> > by doing this.
> 
> Additionally, could you, in the case of a redirection, add a message
> saying "You were redirected here because the binary package XX is in the
> source package YY." ?

The obvious solution is to use a mod_rewrite map for packages with multiple
sources via the PTS sources.map.

Something like [not tested]:

RewriteMap binaries dbm:binaries.db
RewriteCond %{REQUEST_URI} ^/([^/]+)$
RewriteCond ${binaries:%1|NonExistantSource} !NonExistantSource
RewriteRule ^/([^/]+)$ /%1 

where binaries.db is a binary: source db whenever binary != source

I have however no idea how to show the message without using trickery.

filippo
--
Filippo Giunchedi - http://esaurito.net
PGP key: 0x6B79D401
random quote follows:

I was once walking through the forest alone. A tree fell right
in front of me -- and I didn't hear it.
-- Steven Wright



Reply to: