1
0
mirror of https://github.com/golang/go synced 2024-11-05 17:06:13 -07:00
go/cmd/goimports
Brad Fitzpatrick 6e57528ade imports: fix reading from stdin on Windows
Don't panic when reading from stdin on Windows. This is a regression
from https://golang.org/cl/43454

Also fix some weird behavior with stdin processing I noticed during
reviewing the code: don't allow the -w (write) flag, and adust the
filename shown with the -d (diff) flag.

Fixes golang/go#20941

Change-Id: I73d0a1dc74c919238a3bb72823585bbf1b7daba1
Reviewed-on: https://go-review.googlesource.com/47810
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Jones <rbjones@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2017-07-07 17:20:05 +00:00
..
doc.go cmd/goimports: update docs to not imply goimports is superset of gofmt 2017-06-13 20:38:26 +00:00
goimports_gc.go cmd/goimports: work around lack of runtime/trace in gccgo 2016-08-13 05:07:58 +00:00
goimports_not_gc.go cmd/goimports: work around lack of runtime/trace in gccgo 2016-08-13 05:07:58 +00:00
goimports.go imports: fix reading from stdin on Windows 2017-07-07 17:20:05 +00:00