diff options
author | Marius Bakke <mbakke@fastmail.com> | 2020-01-11 22:38:24 +0100 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2020-01-11 22:38:24 +0100 |
commit | b7bf02a418e946b610ef68e8c5131f2350835956 (patch) | |
tree | 6d84387279b9870dc0b151bb9d3dce7f9d9de73d /gnu/packages/javascript.scm | |
parent | 233c1be0a30846f6646b1f4edc6257037d0835fc (diff) | |
parent | 13efb24850bc40fab2448771c87c77c9a69fc231 (diff) | |
download | guix-b7bf02a418e946b610ef68e8c5131f2350835956.tar guix-b7bf02a418e946b610ef68e8c5131f2350835956.tar.gz |
Merge branch 'master' into core-updates
Diffstat (limited to 'gnu/packages/javascript.scm')
-rw-r--r-- | gnu/packages/javascript.scm | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index 6718274da2..83fa5ede4c 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -25,7 +25,6 @@ #:use-module (gnu packages) #:use-module (gnu packages base) #:use-module (gnu packages compression) - #:use-module (gnu packages lisp) #:use-module (gnu packages lisp-xyz) #:use-module (gnu packages readline) #:use-module (guix packages) @@ -453,50 +452,3 @@ to use, and is very similar to Lua. There is no need to interact with byzantine C++ template mechanisms, or worry about marking and unmarking garbage collection roots, or wrestle with obscure build systems.") (license license:isc))) - -(define-public uglify-js - (package - (inherit sbcl-cl-uglify-js) - (name "uglify-js") - (build-system trivial-build-system) - (arguments - `(#:modules ((guix build utils)) - #:builder - (let* ((bin (string-append (assoc-ref %outputs "out") "/bin/")) - (script (string-append bin "uglify-js"))) - (use-modules (guix build utils)) - (mkdir-p bin) - (with-output-to-file script - (lambda _ - (format #t "#!~a/bin/sbcl --script - (require :asdf) - (push (truename \"~a/lib/sbcl\") asdf:*central-registry*)" - (assoc-ref %build-inputs "sbcl") - (assoc-ref %build-inputs "sbcl-cl-uglify-js")) - ;; FIXME: cannot use progn here because otherwise it fails to - ;; find cl-uglify-js. - (for-each - write - '(;; Quiet, please! - (let ((*standard-output* (make-broadcast-stream)) - (*error-output* (make-broadcast-stream))) - (asdf:load-system :cl-uglify-js)) - (let ((file (cadr *posix-argv*))) - (if file - (format t "~a" - (cl-uglify-js:ast-gen-code - (cl-uglify-js:ast-mangle - (cl-uglify-js:ast-squeeze - (with-open-file (in file) - (parse-js:parse-js in)))) - :beautify nil)) - (progn - (format *error-output* - "Please provide a JavaScript file.~%") - (sb-ext:exit :code 1)))))))) - (chmod script #o755) - #t))) - (inputs - `(("sbcl" ,sbcl) - ("sbcl-cl-uglify-js" ,sbcl-cl-uglify-js))) - (synopsis "JavaScript compressor"))) |