diff options
author | Mathieu Lirzin <mthl@openmailbox.org> | 2015-08-27 17:51:11 +0200 |
---|---|---|
committer | Mathieu Lirzin <mthl@openmailbox.org> | 2015-09-11 22:48:03 +0200 |
commit | dd5c9902adaacc6240085149ed10b8af7f511f6b (patch) | |
tree | f34579f8de5ac1dbf7f44c2f49513a5ae13e27a0 | |
parent | 6760361b1026e13be3e6730e70cda9e878242ce1 (diff) | |
download | guix-artwork-dd5c9902adaacc6240085149ed10b8af7f511f6b.tar guix-artwork-dd5c9902adaacc6240085149ed10b8af7f511f6b.tar.gz |
website: packages: Support Texinfo's markup.
* website/www/packages.scm (package->sxml): Adapt to new Texinfo's
markup in package description.
-rw-r--r-- | website/www/packages.scm | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/website/www/packages.scm b/website/www/packages.scm index 09da932..fe4fb2b 100644 --- a/website/www/packages.scm +++ b/website/www/packages.scm @@ -37,6 +37,8 @@ #:use-module (ice-9 i18n) #:use-module (srfi srfi-1) #:use-module (srfi srfi-19) + #:use-module (texinfo) + #:use-module (texinfo html) #:export (packages-page)) (define lookup-gnu-package @@ -170,6 +172,12 @@ decreasing, is 1." (package-transitive-supported-systems package))) " "))) + (define (package-description-shtml package) + "Return a SXML representation of PACKAGE description field with HTML +vocabulary." + (and=> (package-description package) + (compose stexi->shtml texi-fragment->stexi))) + (define (package-logo name) (and=> (lookup-gnu-package name) gnu-package-logo)) @@ -203,7 +211,7 @@ description-ids as formal parameters." (class "package-logo") (alt ("Logo of " ,(package-name package)))))) (_ #f)) - (p ,(package-description package)) + (p ,(package-description-shtml package)) ,(license package) (a (@ (href ,(package-home-page package)) (title "Link to the package's website")) |