docs/generate: remove uses of pkg/errors

While there may be reasons to keep pkg/errors in production code,
we don't need them for this generator code.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2025-03-19 10:49:16 +01:00
parent ecfdf74115
commit 2f795987d6
+2 -2
View File
@@ -5,6 +5,7 @@
package main
import (
"errors"
"log"
"os"
@@ -12,7 +13,6 @@ import (
"github.com/docker/cli/cli"
"github.com/docker/cli/cli/command"
"github.com/docker/cli/cli/command/commands"
"github.com/pkg/errors"
"github.com/spf13/cobra"
"github.com/spf13/pflag"
)
@@ -64,7 +64,7 @@ func gen(opts *options) error {
return err
}
default:
return errors.Errorf("unknown format %q", format)
return errors.New("unknown format: " + format)
}
}