guix-patches
[Top][All Lists]
Advanced

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

bug#27049: [PATCH 2/2] gnu: Add js-mathjax.


From: Ludovic Courtès
Subject: bug#27049: [PATCH 2/2] gnu: Add js-mathjax.
Date: Sat, 03 Jun 2017 15:53:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Arun Isaac <address@hidden> skribis:

> * gnu/packages/javascript.scm: New file.
> * gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
> * gnu/packages/javascript.scm (js-mathjax): New variable.

[...]

> +           (for-each
> +            (lambda (file)
> +              (let ((install-path (string-append install-directory
> +                                                 ;; remove prefix "."
> +                                                 (string-drop file 1))))
> +                (format #t "~a -> ~a~%" file install-path)
> +                (cond
> +                 ((string-match "\\.js$" file)
> +                  (mkdir-p (dirname install-path))
> +                  (system (format #f "uglify-js ~a > ~a" file install-path)))
> +                 (else
> +                  (install-file file (dirname install-path))))))
> +            (find-files "."))))))

Nitpick: in GNU “path” is used to denote search paths; we use “file
names” for files.  So s/install-path/installed-file/ or something like
that.

(I already wrote about ‘system’ in another message.)

Otherwise LGTM, thanks!

Ludo’.





reply via email to

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