Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

Add a question about requiring packages with no Go code to the FAQ #1272

Closed
@ibrasho

Description

@ibrasho

We should add a question to the FAQ to clarify how to add cli tools like staticcheck (from honnef.co/go/tools) ... etc.

If someone attempts to add honnef.co/go/tools to their required packages they will get the following error:

master: Could not introduce honnef.co/go/tools@master, as its subpackage honnef.co/go/tools does not contain usable Go code (*build.NoGoError).. (Package is required by (root).)

since dep expect the required package to contain some Go code.

The solution is to require a package that contains the actual code (e.g. honnef.co/go/tools/cmd/staticcheck or honnef.co/go/tools/cmd/megacheck).

Note: we should clearly state that all tools should be added to required, as prune might remove packages that are not required.

See #1263.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions