diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2020-12-30 14:53:03 +0100 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2020-12-30 15:08:31 +0100 |
commit | 4408c4d046965fe4a99a72043ec42c730f94fb5e (patch) | |
tree | 1a016e59967ab45d39bd319dd727e7551451e4d3 /gnu/packages | |
parent | 8b036927a45fb2c1428badabdc3dc0d9d51f7f25 (diff) | |
download | guix-4408c4d046965fe4a99a72043ec42c730f94fb5e.tar.gz |
gnu: Add js-commander.
* gnu/packages/javascript.scm (js-commander): New variable.
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/javascript.scm | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index c4bce1c42e..aed2ead719 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -187,6 +187,45 @@ plugins or software to be installed on the browser. So the page author can write web documents that include mathematics and be confident that readers will be able to view it naturally and easily."))) +(define-public js-commander + (package + (name "js-commander") + (version "6.2.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/tj/commander.js") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "126m25s6mxpxmdj4aw5awz06b47r8r798lcf1c5bnmmh39cik5i1")))) + (build-system trivial-build-system) + (arguments + `(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (chdir (assoc-ref %build-inputs "source")) + (let ((esbuild (string-append (assoc-ref %build-inputs "esbuild") + "/bin/esbuild")) + (target (string-append %output "/share/javascript/commander"))) + (invoke esbuild + "--bundle" + "--minify" + "--tsconfig=tsconfig.json" + "--platform=node" + (string-append "--outfile=" target "/index.min.js") + "index.js"))))) + (native-inputs + `(("esbuild" ,esbuild))) + (home-page "https://github.com/tj/commander.js") + (synopsis "Library for node.js command-line interfaces") + (description "Commander.js aims to be the complete solution for node.js +command-line interfaces. ") + (license license:expat))) + (define-public js-respond (package (name "js-respond") |