summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/golang.scm14
-rw-r--r--gnu/packages/patches/go-github-com-urfave-cli-v2-fix-tests.patch37
3 files changed, 8 insertions, 44 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 957726989e..d4ebfbeb65 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1506,7 +1506,6 @@ dist_patch_DATA = \
%D%/packages/patches/go-fix-script-tests.patch \
%D%/packages/patches/go-gopkg-in-yaml-v3-32bit.patch \
%D%/packages/patches/go-github-com-golang-snappy-32bit-test.patch \
- %D%/packages/patches/go-github-com-urfave-cli-v2-fix-tests.patch \
%D%/packages/patches/go-github-com-warpfork-go-wish-fix-tests.patch \
%D%/packages/patches/go-github-com-wraparound-wrap-free-fonts.patch \
%D%/packages/patches/go-skip-gc-test.patch \
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index a1e4c73ef3..3784ec9a42 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -4242,7 +4242,7 @@ fast and distributable command line applications in an expressive way.")
(package
(inherit go-github-com-urfave-cli)
(name "go-github-com-urfave-cli-v2")
- (version "2.3.0")
+ (version "2.27.5")
(source
(origin
(method git-fetch)
@@ -4251,12 +4251,14 @@ fast and distributable command line applications in an expressive way.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "08pvn7gyfznni72xrxfh2x6xxa8ykr7l1ka278js8g8qkh71bj8l"))
- ;; XXX: Remove patch when updating.
- (patches
- (search-patches "go-github-com-urfave-cli-v2-fix-tests.patch"))))
+ (base32 "03237hi2jqvms9cif4varyap3j1dhzcf1mr809dm7ncvzk7gxg83"))))
(arguments
- '(#:import-path "github.com/urfave/cli/v2"))))
+ '(#:import-path "github.com/urfave/cli/v2"))
+ (propagated-inputs
+ (list go-github-com-burntsushi-toml
+ go-github-com-go-md2man
+ go-github-com-xrash-smetrics
+ go-gopkg-in-yaml-v3))))
(define-public go-github-com-go-md2man
(package
diff --git a/gnu/packages/patches/go-github-com-urfave-cli-v2-fix-tests.patch b/gnu/packages/patches/go-github-com-urfave-cli-v2-fix-tests.patch
deleted file mode 100644
index 87ccc2b655..0000000000
--- a/gnu/packages/patches/go-github-com-urfave-cli-v2-fix-tests.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From upstream PR: https://github.com/urfave/cli/pull/1299
-
-From: William Wilson <william.wilson@canonical.com>
-Date: Tue, 31 Aug 2021 14:19:17 -0500
-Subject: Make test case compatible with Go 1.17
-
-As of Go 1.17, the go flag package will panic if given a syntactically invalid
-flag. This causes TestApp_RunAsSubCommandIncorrectUsage to panic and therefore
-fail. See https://golang.org/doc/go1.17#flag for more information.
-
----
-diff --git a/app_test.go b/app_test.go
-index 7c38f6048..76e211d68 100644
---- a/app_test.go
-+++ b/app_test.go
-@@ -476,18 +476,18 @@ func TestApp_RunAsSubCommandIncorrectUsage(t *testing.T) {
- a := App{
- Name: "cmd",
- Flags: []Flag{
-- &StringFlag{Name: "--foo"},
-+ &StringFlag{Name: "foo"},
- },
- Writer: bytes.NewBufferString(""),
- }
-
- set := flag.NewFlagSet("", flag.ContinueOnError)
-- _ = set.Parse([]string{"", "---foo"})
-+ _ = set.Parse([]string{"", "-bar"})
- c := &Context{flagSet: set}
-
- err := a.RunAsSubcommand(c)
-
-- expect(t, err, errors.New("bad flag syntax: ---foo"))
-+ expect(t, err.Error(), "flag provided but not defined: -bar")
- }
-
- func TestApp_CommandWithFlagBeforeTerminator(t *testing.T) {