diff options
author | Wilko Meyer <w@wmeyer.eu> | 2023-10-18 11:38:20 +0200 |
---|---|---|
committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2024-04-09 17:14:52 +0100 |
commit | e8d3d5224ebd200a025a514a558fb63c60701332 (patch) | |
tree | 651f0198e6d460343d267df6a2d7f3eb7428d3c5 | |
parent | d43b4d77581c6e330ff974d5c2108bbe09735ba4 (diff) |
gnu: Add miller.
* gnu/packages/textutils.scm (miller): New variable.
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Change-Id: Ic381b5e28e561382c49f843aa1baadf2d2d6f294
-rw-r--r-- | gnu/packages/textutils.scm | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/gnu/packages/textutils.scm b/gnu/packages/textutils.scm index ff42f748ea..e5cb96d524 100644 --- a/gnu/packages/textutils.scm +++ b/gnu/packages/textutils.scm @@ -69,6 +69,7 @@ #:use-module (gnu packages golang) #:use-module (gnu packages golang-build) #:use-module (gnu packages golang-check) + #:use-module (gnu packages golang-compression) #:use-module (gnu packages golang-crypto) #:use-module (gnu packages golang-xyz) #:use-module (gnu packages java) @@ -1535,6 +1536,60 @@ JSON for post-processing (define-public go-github-com-aswinkarthik-csvdiff (deprecated-package "go-github-com-aswinkarthik-csvdiff" csvdiff)) +(define-public miller + (package + (name "miller") + (version "6.12.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/johnkerl/miller") + (commit (go-version->git-ref version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "195lgayq5z7ndag3w495fs618pkrhz426kg0kp3s5sa68vr1madp")))) + (build-system go-build-system) + (arguments + (list + #:go go-1.19 + #:install-source? #f + #:import-path "github.com/johnkerl/miller/cmd/mlr" + #:unpack-path "github.com/johnkerl/miller" + #:phases + #~(modify-phases %standard-phases + ;; TODO: Build all provided documentation. + (add-after 'install 'install-man-pages + (lambda* (#:key unpack-path #:allow-other-keys) + (with-directory-excursion (string-append "src/" unpack-path) + (invoke "make" (string-append "PREFIX=" #$output) + "-C" "man" "install"))))))) + (native-inputs + (list go-github-com-facette-natsort + go-github-com-johnkerl-lumin + go-github-com-kballard-go-shellquote + go-github-com-klauspost-compress + go-github-com-lestrrat-go-strftime + go-github-com-mattn-go-isatty + ;; Optional, not packed in Guix + ;; go-github-com-nine-lives-later-go-windows-terminal-sequences + go-github-com-pkg-profile + go-github-com-stretchr-testify + go-golang-org-x-sys + go-golang-org-x-term + go-golang-org-x-text + python-wrapper + python-mkdocs-material + ruby)) + (home-page "https://miller.readthedocs.io/") + (synopsis "Text-formatted data processing tool") + (description + "Miller (@command{mlr}) is like @command{awk}, @command{sed}, +@command{cut}, @command{join}, and @command{sort} for data formats such as +CSV, TSV, JSON, JSON Lines, and positionally-indexed. It supports format +conversion and pretty-printing.") + (license license:bsd-2))) + (define-public ack (package (name "ack") |