From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH] website: Convert implementation to SXML. Date: Wed, 06 May 2015 21:09:31 +0200 Message-ID: <87vbg5setw.fsf@gnu.org> References: <87r3qt3dqt.fsf@openmailbox.org> <87egmt4rfz.fsf@fsf.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45934) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yq4hP-00074P-IM for guix-devel@gnu.org; Wed, 06 May 2015 15:09:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yq4hK-0005VF-J5 for guix-devel@gnu.org; Wed, 06 May 2015 15:09:39 -0400 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:59109) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yq4hK-0005VB-G1 for guix-devel@gnu.org; Wed, 06 May 2015 15:09:34 -0400 In-Reply-To: <87egmt4rfz.fsf@fsf.org> (David Thompson's message of "Wed, 06 May 2015 12:10:56 -0400") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: David Thompson Cc: guix-devel@gnu.org David Thompson skribis: > Mathieu Lirzin writes: > >> This patch is a draft for the html->sxml website conversion. > > Looking good! Indeed! > But, I have one comment overall about our development strategy: > > I see a lot of absolute paths like > '/software/guix/static/base/css/base.css'. These will of course work > when viewing the site on gnu.org, but how do we develop the site on our > own computers? I was wondering too, does IceCat have a plug-in to specify the root of such URLs? > Ideally, I'd like to be able to generate the site and serve it with > Guile's HTTP server to see what the result looks like before > committing patches. Sure. I think what Mathieu provides is a good first step, and I=E2=80=99ll happily commit the wrapped-lines version if there are no objections. The next step would be to introduce a (www utils) module, say. It would have, among other things: (define current-url-root (make-parameter "/")) (define (static-url-base) (string-append (current-url-root) "/static/base")) (define (css-url file) (string-append (static-url-base) "/css")) and so on. The pages would be modified to use these procedures instead of hard-coded paths. How does that sound? Thanks, Mathieu! Ludo=E2=80=99.