cmd/go/internal/list: add module support

This CL changes the clumsy hard-coded "list -m" and "list -m -u"
with a real template-based implementation analogous to what we
do for listing packages. (In fact it reuses most of the package
implementation.) See the documentation for more details.

The main visible changes compared to the original vgo are:

- "vgo list -m" is now "vgo list -m all".
- "vgo list -m -u" is now "vgo list -m -u all".
- The default output is no longer a fixed-width-aligned table.
- The output no longer has COLUMN HEADERS.
- "vgo list -m -json [all]" now works.

Fixes golang/go#24347.
Fixes golang/go#25360.

Change-Id: Ie6a677875abca876ae334c8554298d3c56076b94
Reviewed-on: https://go-review.googlesource.com/120198
Reviewed-by: Bryan C. Mills <bcmills@google.com>
12 files changed
tree: 708af43b76d019a5ffbb5ce2e8a7c6330e5224ce
  1. AUTHORS
  2. CONTRIBUTING.md
  3. CONTRIBUTORS
  4. LICENSE
  5. PATENTS
  6. README.md
  7. codereview.cfg
  8. main.go
  9. vendor/
README.md

Versioned Go Prototype (vgo)

This repository holds a prototype of what the go command might look like with integrated support for package versioning.

See research.swtch.com/vgo for documents about the design.

Download/Install

Use go get -u golang.org/x/vgo.

You can also manually git clone the repository to $GOPATH/src/golang.org/x/vgo.

Report Issues / Send Patches

See CONTRIBUTING.md.

This is still a very early prototype. You are likely to run into bugs. Please file bugs in the main Go issue tracker, golang.org/issue, and put the prefix x/vgo: in the issue title.

Thank you.