如标题,遇到此问题:
$ go run pdfeditor.go
..\..\sirupsen\logrus\terminal_check_windows.go:9:2:
..\..\..\golang.org\x\sys\windows\syscall_test.go:10:1: expected 'STRING', found '<<'
..\..\..\golang.org\x\sys\windows\syscall_test.go:22:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:26:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:29:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:45:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:49:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:52:2: expected 'STRING', found 'const'
..\..\..\golang.org\x\sys\windows\syscall_test.go:54:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:63:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:66:2: expected 'STRING', found 'if'
..\..\..\golang.org\x\sys\windows\syscall_test.go:70:50: expected ')', found 'EOF'
貌似是相应组件在windows上已经损坏了,我删除掉golang.org/x/,重新go get -u 挨个恢复就好了,go get 需要代理。
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 crypto/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 exp/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 image/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 lint/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 mobile/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 net/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 oauth2/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 sys/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 text/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 time/
drwxr-xr-x 1 Administrator 197121 0 六月 15 09:31 tools/