From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34464) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dH9VD-0000hn-KG for guix-patches@gnu.org; Sat, 03 Jun 2017 09:54:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dH9VC-0007S8-NH for guix-patches@gnu.org; Sat, 03 Jun 2017 09:54:03 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:49810) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dH9VC-0007S4-J4 for guix-patches@gnu.org; Sat, 03 Jun 2017 09:54:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dH9VC-0005zn-Cx for guix-patches@gnu.org; Sat, 03 Jun 2017 09:54:02 -0400 Subject: bug#27049: [PATCH 2/2] gnu: Add js-mathjax. Resent-Message-ID: From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) References: <20170602203308.7606-1-arunisaac@systemreboot.net> <846e49f4.AEUAKzpfUbYAAAAAAAAAAAPEb_oAAAACwQwAAAAAAAW9WABZMcuW@mailjet.com> Date: Sat, 03 Jun 2017 15:53:42 +0200 In-Reply-To: <846e49f4.AEUAKzpfUbYAAAAAAAAAAAPEb_oAAAACwQwAAAAAAAW9WABZMcuW@mailjet.com> (Arun Isaac's message of "Sat, 3 Jun 2017 02:03:08 +0530") Message-ID: <87zidpkwih.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Arun Isaac Cc: 27049@debbugs.gnu.org Arun Isaac 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-pa= th))) > + (else > + (install-file file (dirname install-path)))))) > + (find-files ".")))))) Nitpick: in GNU =E2=80=9Cpath=E2=80=9D is used to denote search paths; we u= se =E2=80=9Cfile names=E2=80=9D for files. So s/install-path/installed-file/ or something l= ike that. (I already wrote about =E2=80=98system=E2=80=99 in another message.) Otherwise LGTM, thanks! Ludo=E2=80=99.