guix-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] Integrate the package list in the website.


From: Ludovic Courtès
Subject: Re: [PATCH] Integrate the package list in the website.
Date: Mon, 15 Jun 2015 22:26:54 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Mathieu Lirzin <address@hidden> skribis:

> I would like some advice on how to add copyright notices in
> 'website/static/base/css/packages.css' and
> 'website/static/base/js/packages.js'. Futhermore I would like
> suggestions about my commit messages, in order to make then
> precise. Other comments or reviews are welcome too ;-)

Both the CSS and JS are under CC0, so I think the simple “license: CC0”
is enough (and hopefully recognized by LibreJS.)

> From aff0743966b06d524acc1d0be86f46b4b0a20828 Mon Sep 17 00:00:00 2001
> From: Mathieu Lirzin <address@hidden>
> Date: Sun, 14 Jun 2015 20:06:40 +0200
> Subject: [PATCH 1/2] website: Allow inclusion of Javascript.
>
> * website/www/utils.scm (js-url): New procedure.
> * website/www/shared.scm (html-page-header): Use it. Add #:js parameter.

[...]

> -(define* (html-page-header title #:key (css "article.css"))
> +(define* (html-page-header title #:key (css "article.css") (js ""))

Make it just js (meaning #:js defaults to #f) and...

> +      ,(if (string-null? js)
> +           ""
> +           `(script (@ (src ,(js-url js))) ""))))

... make it ,(if js `(script ...) "").
(It’s more idiomatic.)

> From ab91cf5468669c80ea13f0540c53e8f8c8faedb5 Mon Sep 17 00:00:00 2001
> From: Mathieu Lirzin <address@hidden>
> Date: Sun, 14 Jun 2015 19:13:12 +0200
> Subject: [PATCH 2/2] website: packages: List packages.
>
> Integrate 'build-aux/list-packages.scm' from the Guix repository in the
> GuixSD website instead of using an external link.  Export of the package
> list is optional since it requires to have Guix locally.
>
> * website/static/base/css/packages.css: New file.
> * website/static/base/js/packages.js: Likewise.
> * website/www.scm (export-web-site): Add #:packages parameter.
> * website/www/packages.scm (lookup-gnu-package, list-join)
>   (package->sxml, packages->sxml): New procedures.
>   (packages-page): Use them.
> * website/www/shared.scm (html-page-description): Use 'packages-page'.

[...]

> --- a/website/www.scm
> +++ b/website/www.scm
> @@ -330,11 +330,7 @@ Distribution.")
>      ("contribute/index.html" ,contribute-page)
>      ("donate/index.html" ,donate-page)
>      ("download/index.html" ,download-page)
> -    ("help/index.html" ,help-page)
> -
> -    ;; XXX: The following one is not ready yet.
> -    ;; ("packages/index.html" ,packages-page)
> -    ))
> +    ("help/index.html" ,help-page)))
>  
>  (define (mkdir* directory)
>    "Make DIRECTORY unless it already exists."
> @@ -353,15 +349,19 @@ Distribution.")
>        (display "<!DOCTYPE html>\n" port)
>        (sxml->xml page port))))
>  
> -(define* (export-web-site #:optional (directory "."))
> -  "Export the whole web site as HTML files created in DIRECTORY."
> +(define* (export-web-site #:optional (directory ".") #:key (packages #f))

I would leave both unchanged.  When we really want to export
package-list.html, we can just add it to %web-pages or use a single call
to ‘export-web-page’.

> From 15b73de6b2910fc1a0a000780c786adc4c0c4404 Mon Sep 17 00:00:00 2001
> From: Mathieu Lirzin <address@hidden>
> Date: Sun, 14 Jun 2015 20:52:42 +0200
> Subject: [PATCH] list-packages: Move to guix-artwork repository.
>
> In order to integrate the package list with the GuixSD website, the listing of
> packages has been moved into the website implementation.
>
> * build-aux/list-packages.scm: Remove file.
> * Makefile.am (EXTRA_DIST): Adapt to it.

OK to push with these changes.

Thank you!

Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]