From 59ce0a11911d7b5fbda6a91b900aabebae55cbea Mon Sep 17 00:00:00 2001 From: Robin Jarry Date: Sun, 23 Apr 2023 21:40:19 +0200 Subject: mod: drop support for go 1.17 A lot of libraries are starting to use generics (introduced in go 1.18). Restricting aerc on 1.17 prevents us from updating our dependencies. Since 1.18 is a major milestone, it has a chance to remain supported for a while. Update the minimum go version to 1.18. Run go mod tidy -compat=1.18. Update our CI to run on 1.18. Signed-off-by: Robin Jarry Acked-by: Bence Ferdinandy --- lib/crypto/gpg/gpg_test.go | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'lib/crypto/gpg') diff --git a/lib/crypto/gpg/gpg_test.go b/lib/crypto/gpg/gpg_test.go index e34cc2bb..25d73693 100644 --- a/lib/crypto/gpg/gpg_test.go +++ b/lib/crypto/gpg/gpg_test.go @@ -3,7 +3,6 @@ package gpg import ( "bytes" "io" - "os" "os/exec" "strings" "testing" @@ -17,13 +16,7 @@ func initGPGtest(t *testing.T) { } // temp dir is automatically deleted by the test runtime dir := t.TempDir() - // t.Setenv is only available since go 1.17 - if err := os.Setenv("GNUPGHOME", dir); err != nil { - t.Fatalf("failed to set GNUPGHOME: %s", err) - } - t.Cleanup(func() { - os.Unsetenv("GNUPGHOME") - }) + t.Setenv("GNUPGHOME", dir) t.Logf("using GNUPGHOME = %s", dir) } -- cgit