summaryrefslogtreecommitdiff
path: root/gnu/packages/shellutils.scm
diff options
context:
space:
mode:
authorSharlatan Hellseher <sharlatanus@gmail.com>2025-10-22 12:42:47 +0100
committerSharlatan Hellseher <sharlatanus@gmail.com>2025-10-22 13:39:25 +0100
commit63dd02eba4e3d4d6bf3b6b9a8801cbdd0da34c3c (patch)
tree26ed09d36916081d3f0ae341c478796bc177b76c /gnu/packages/shellutils.scm
parentd68f993e1c2a3dd72083d4f3b124d09ba661dcf1 (diff)
gnu: shfmt: Update to 3.12.0.
* gnu/packages/shellutils.scm (shfmt): Update to 3.12.0. [source] <snippet>: Delete "cmd/gosh" which causes build of "shfmt" to fail. [arguments] <test-flags>: Skip tests requiring altering locale. <test-subdirs>: Run tests for the whole project. <phases>: Use default 'check. [native-inputs]: Remove go-github-com-muesli-cancelreader, go-github-com-rogpeppe-go-internal, and go-golang-org-x-sync; add go-github-com-rogpeppe-go-internal-1.14. [description]: Fix indentation. Change-Id: Ifecc8891d7c9e3cd112c724ce1da8f5461779696
Diffstat (limited to 'gnu/packages/shellutils.scm')
-rw-r--r--gnu/packages/shellutils.scm43
1 files changed, 26 insertions, 17 deletions
diff --git a/gnu/packages/shellutils.scm b/gnu/packages/shellutils.scm
index 71d9cee818c..cdaab7f7954 100644
--- a/gnu/packages/shellutils.scm
+++ b/gnu/packages/shellutils.scm
@@ -443,22 +443,39 @@ all of the regexes given on the command line in order.")
443(define-public shfmt 443(define-public shfmt
444 (package 444 (package
445 (name "shfmt") 445 (name "shfmt")
446 (version "3.9.0") 446 (version "3.12.0")
447 (source 447 (source
448 (origin 448 (origin
449 (method git-fetch) 449 (method git-fetch)
450 (uri (git-reference 450 (uri (git-reference
451 (url "https://github.com/mvdan/sh") 451 (url "https://github.com/mvdan/sh")
452 (commit (string-append "v" version)))) 452 (commit (string-append "v" version))))
453 (file-name (git-file-name name version)) 453 (file-name (git-file-name name version))
454 (sha256 454 (sha256
455 (base32 "0qqrggliwicmrqzwv9ivg7w1chy1b97w8p7ifpvqfsbal0qcr1xi")))) 455 (base32 "11rlx3l37aspd9674xdisw394bdly0yb38asqxaz4riadgj0vbfx"))
456 (modules '((guix build utils)))
457 (snippet
458 #~(begin
459 ;; It fails during check phase, looks like a MVP: gosh is a proof
460 ;; of concept shell built on top of [interp].
461 (delete-file-recursively "cmd/gosh")))))
456 (build-system go-build-system) 462 (build-system go-build-system)
457 (arguments 463 (arguments
458 (list 464 (list
459 #:install-source? #f 465 #:install-source? #f
460 #:import-path "mvdan.cc/sh/v3/cmd/shfmt" 466 #:import-path "mvdan.cc/sh/v3/cmd/shfmt"
461 #:unpack-path "mvdan.cc/sh/v3" 467 #:unpack-path "mvdan.cc/sh/v3"
468 #:test-flags
469 ;; Tests fail for these groups unable to set locale.
470 #~(list "-skip" (string-join
471 (list "FuzzQuote"
472 "TestKillTimeout"
473 "TestParseBashConfirm"
474 "TestParseErrBashConfirm"
475 "TestRunnerRun"
476 "TestRunnerRunConfirm")
477 "|"))
478 #:test-subdirs #~(list "../../...") ;test the whole libary
462 #:phases 479 #:phases
463 #~(modify-phases %standard-phases 480 #~(modify-phases %standard-phases
464 (add-after 'unpack 'set-version 481 (add-after 'unpack 'set-version
@@ -472,21 +489,13 @@ all of the regexes given on the command line in order.")
472 (("version = \"\\(devel\\)\"") 489 (("version = \"\\(devel\\)\"")
473 (format #f "version = \"~a\"" fixed-version))) 490 (format #f "version = \"~a\"" fixed-version)))
474 (substitute* "cmd/shfmt/testdata/script/flags.txtar" 491 (substitute* "cmd/shfmt/testdata/script/flags.txtar"
475 (("devel\\|v3") #$version)))))) 492 (("devel\\|v3") #$version)))))))))
476 ;; XXX: Replace when go-build-system supports nested path.
477 (replace 'check
478 (lambda* (#:key import-path tests? #:allow-other-keys)
479 (when tests?
480 (with-directory-excursion (string-append "src/" import-path)
481 (invoke "go" "test" "-v" "./..."))))))))
482 (native-inputs 493 (native-inputs
483 (list go-github-com-creack-pty 494 (list go-github-com-creack-pty
484 go-github-com-go-quicktest-qt 495 go-github-com-go-quicktest-qt
485 go-github-com-google-go-cmp 496 go-github-com-google-go-cmp
486 go-github-com-google-renameio-v2 497 go-github-com-google-renameio-v2
487 go-github-com-muesli-cancelreader 498 go-github-com-rogpeppe-go-internal-1.14
488 go-github-com-rogpeppe-go-internal
489 go-golang-org-x-sync
490 go-golang-org-x-sys 499 go-golang-org-x-sys
491 go-golang-org-x-term 500 go-golang-org-x-term
492 go-mvdan-cc-editorconfig)) 501 go-mvdan-cc-editorconfig))
@@ -494,9 +503,9 @@ all of the regexes given on the command line in order.")
494 (synopsis "Shell formatter with bash support") 503 (synopsis "Shell formatter with bash support")
495 (description 504 (description
496 "This package provides a shell formatter. Supports 505 "This package provides a shell formatter. Supports
497@url{https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html,POSIX 506@url{https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html,
498Shell}, @url{https://www.gnu.org/software/bash/,Bash}, and 507POSIX Shell}, @url{https://www.gnu.org/software/bash/, Bash}, and
499@url{http://www.mirbsd.org/mksh.htm,mksh}.") 508@url{http://www.mirbsd.org/mksh.htm, mksh}.")
500 (license license:bsd-3))) 509 (license license:bsd-3)))
501 510
502(define-public starship 511(define-public starship