mirror of
https://github.com/golang/go.git
synced 2025-05-05 15:43:04 +00:00
If GO111MODULE=on but there's no go.mod, GOMOD will be set to /dev/null or NUL and there will be no main module. goimports should handle this case roughly the same way the go command does. Fixes golang/go#30855 Change-Id: I6fbf4c056000db5abd8788a6014ae5f13b1c8cd4 Reviewed-on: https://go-review.googlesource.com/c/tools/+/167860 Run-TryBot: Heschi Kreinick <heschi@google.com> Reviewed-by: Ian Cottrell <iancottrell@google.com>