From dc8eb0b77793c31ade74c67d5b5ed1d0623cda65 Mon Sep 17 00:00:00 2001 From: Eric Leijonmarck Date: Fri, 12 Aug 2022 14:57:42 +0100 Subject: [PATCH] Print package error message for deprecated io/ioutil (#53665) * Add: package error message for io/util * added a ioutil for testing ci * Revert "added a ioutil for testing ci" This reverts commit 8c324ccf8a48b4c89d8301933f60886f8eaecba3. * removed spaces --- conf/.golangci.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/conf/.golangci.toml b/conf/.golangci.toml index d2a5946267c..857c978d842 100644 --- a/conf/.golangci.toml +++ b/conf/.golangci.toml @@ -17,6 +17,8 @@ confidence = 3 list-type = "blacklist" include-go-root = true packages = ["io/ioutil"] +[[linters-settings.depguard.packages-with-error-message]] +"io/ioutil" = "Deprecated: As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details." [linters-settings.gocritic] enabled-checks = ["ruleguard"]