mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-16 11:55:27 -05:00
gnu: r-colourpicker: Update to 1.1.1.
* gnu/packages/cran.scm (r-colourpicker): Update to 1.1.1. [arguments]: Remove modules; use esbuild in build phase 'process-javascript. [native-inputs]: Remove r-knitr and uglifyjs; add esbuild; change js-jquery version.
This commit is contained in:
parent
545a2f78a5
commit
2f61f562bb
1 changed files with 18 additions and 28 deletions
|
@ -15497,45 +15497,36 @@ (define-public r-shinyjs
|
||||||
(define-public r-colourpicker
|
(define-public r-colourpicker
|
||||||
(package
|
(package
|
||||||
(name "r-colourpicker")
|
(name "r-colourpicker")
|
||||||
(version "1.1.0")
|
(version "1.1.1")
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (cran-uri "colourpicker" version))
|
(uri (cran-uri "colourpicker" version))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"1qjispj7i12m02js5cm5xlgn5lyff0kc5ybz6lbknz8q5lkbdyrd"))))
|
"1q1wi3g403fbzp4ys3gsjbwdc86x770cx323qgi47ca8n219kl50"))))
|
||||||
(build-system r-build-system)
|
(build-system r-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:modules ((guix build utils)
|
`(#:phases
|
||||||
(guix build r-build-system)
|
|
||||||
(srfi srfi-1)
|
|
||||||
(ice-9 popen))
|
|
||||||
#:phases
|
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'process-javascript
|
(add-after 'unpack 'process-javascript
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(with-directory-excursion "inst"
|
(with-directory-excursion "inst"
|
||||||
(call-with-values
|
(let ((mapping
|
||||||
(lambda ()
|
|
||||||
(unzip2
|
|
||||||
`((,(assoc-ref inputs "js-salvattore")
|
`((,(assoc-ref inputs "js-salvattore")
|
||||||
"examples/colourInput/www/salvattore.min.js")
|
. "examples/colourInput/www/salvattore.min.js")
|
||||||
(,(assoc-ref inputs "js-jquery")
|
(,(assoc-ref inputs "js-jquery")
|
||||||
"htmlwidgets/lib/jquery/jquery.min.js")
|
. "htmlwidgets/lib/jquery/jquery.min.js")
|
||||||
("www/shared/colourpicker/js/colourpicker.js"
|
("www/shared/colourpicker/js/colourpicker.js"
|
||||||
"www/shared/colourpicker/js/colourpicker.min.js"))))
|
. "www/shared/colourpicker/js/colourpicker.min.js"))))
|
||||||
(lambda (sources targets)
|
(for-each (lambda (source target)
|
||||||
(for-each (lambda (source target)
|
(format #true "Processing ~a --> ~a~%"
|
||||||
(format #t "Processing ~a --> ~a~%"
|
source target)
|
||||||
source target)
|
(delete-file target)
|
||||||
(delete-file target)
|
(invoke "esbuild" source "--minify"
|
||||||
(let ((minified (open-pipe* OPEN_READ "uglifyjs" source)))
|
(string-append "--outfile=" target)))
|
||||||
(call-with-output-file target
|
(map car mapping)
|
||||||
(lambda (port)
|
(map cdr mapping)))))))))
|
||||||
(dump-port minified port)))))
|
|
||||||
sources targets))))
|
|
||||||
#t)))))
|
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
`(("r-ggplot2" ,r-ggplot2)
|
`(("r-ggplot2" ,r-ggplot2)
|
||||||
("r-htmltools" ,r-htmltools)
|
("r-htmltools" ,r-htmltools)
|
||||||
|
@ -15545,15 +15536,14 @@ (define-public r-colourpicker
|
||||||
("r-shiny" ,r-shiny)
|
("r-shiny" ,r-shiny)
|
||||||
("r-shinyjs" ,r-shinyjs)))
|
("r-shinyjs" ,r-shinyjs)))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("r-knitr" ,r-knitr)
|
`(("esbuild" ,esbuild)
|
||||||
("uglifyjs" ,node-uglify-js)
|
|
||||||
("js-jquery"
|
("js-jquery"
|
||||||
,(origin
|
,(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri "https://code.jquery.com/jquery-3.3.1.js")
|
(uri "https://code.jquery.com/jquery-1.11.3.js")
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"1b8zxrp6xwzpw25apn8j4qws0f6sr7qr7h2va5h1mjyfqvn29anq"))))
|
"1v956yf5spw0156rni5z77hzqwmby7ajwdcd6mkhb6zvl36awr90"))))
|
||||||
("js-salvattore"
|
("js-salvattore"
|
||||||
,(origin
|
,(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
|
|
Loading…
Reference in a new issue