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

Re: Bug#522733: Debian Developer's Reference: FR instead of EN / broken links



Hello,

On Wed, Apr 08, 2009 at 08:56:55AM +0200, Jens Seidel wrote:
> On Tue, Apr 07, 2009 at 02:36:40PM -0700, Matt Kraai wrote:
> > On Tue, Apr 07, 2009 at 09:47:21PM +0200, Simon Paillard wrote:
> > > symlinks index.html.$lang -> index.$lang.html can be created in the cron
> > > task that updates the doc.
> > 
> > Most of the links on the Debian website don't use any extensions.
> > Would it be possible to modify the developer's reference to do the
> > same?
> 
> A problem could be delivering offline documents which are readable without
> installed webserver.

Agrees, here is a patch against the cron that creates for each file
filename.html.$lang -> filename.$lang.html (except for japanese, see
below).
 
> >  If not, I think we'll have to have the symbolic links, but I
> > think that would prevent language negotiation from working for other
> > languages.
> 
> Or simply adapt the build system to either respect a variable which expands
> to either ".html" or "" or to remove ".html" via sed/perl if build on
> www-master ...

Concerning the devref, the files are taken from the packages (except
concerning http://debian.org/doc/manuals/developers-reference/index.ja.html
whose I don't understand the origin from the cron cvs). 

Can someone point the place where this copy/build is perfomered ?

Regards.

-- 
Simon Paillard
--- cron.orig	2009-04-14 22:27:29.000000000 +0200
+++ cron	2009-04-14 22:38:23.000000000 +0200
@@ -74,9 +74,12 @@
 for doc in dr/usr/share/doc/developers-reference/*.html
 do
 	install -p -m 664 "$doc" $webdocdir/developers-reference/$(basename "$doc" .html).en.html
+	ln -sf $webdocdir/developers-reference/$(basename "$doc" .html).en.html $webdocdir/developers-reference/$(basename "$doc" .html).html.en
 done
 install -p -m 664 dr/usr/share/doc/developers-reference/developers-reference.pdf $webdocdir/developers-reference/developers-reference.en.pdf
+ln -sf $webdocdir/developers-reference/developers-reference.en.pdf $webdocdir/developers-reference/developers-reference.pdf.en
 install -p -m 664 dr/usr/share/doc/developers-reference/developers-reference.txt.gz $webdocdir/developers-reference/developers-reference.en.txt.gz
+ln -sf $webdocdir/developers-reference/developers-reference.en.txt.gz $webdocdir/developers-reference/developers-reference.txt.gz.en
 rm -rf dr
 
 drdeb=`ls -t1 $ftpdir/pool/main/d/developers-reference/developers-reference-fr_*.deb | head -1`
@@ -85,9 +88,12 @@
 for doc in dr/usr/share/doc/developers-reference-fr/*.html
 do
 	install -p -m 664 "$doc" $webdocdir/developers-reference/$(basename "$doc" .html).fr.html
+	ln -sf $webdocdir/developers-reference/$(basename "$doc" .html).fr.html $webdocdir/developers-reference/$(basename "$doc" .html).html.fr
 done
 install -p -m 664 dr/usr/share/doc/developers-reference-fr/developers-reference.pdf $webdocdir/developers-reference/developers-reference.fr.pdf
+ln -sf $webdocdir/developers-reference/developers-reference.fr.pdf $webdocdir/developers-reference/developers-reference.pdf.fr
 install -p -m 664 dr/usr/share/doc/developers-reference-fr/developers-reference.txt.gz $webdocdir/developers-reference/developers-reference.fr.txt.gz
+ln -sf $webdocdir/developers-reference/developers-reference.fr.txt.gz $webdocdir/developers-reference/developers-reference.txt.gz.fr
 rm -rf dr
 
 echo -n " maint-guide"

Reply to: