소스 검색

Command -> LookPath

RPRX 5 년 전
부모
커밋
2aedff1218
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      infra/vprotogen/main.go

+ 1 - 1
infra/vprotogen/main.go

@@ -26,7 +26,7 @@ func main() {
 	}
 	protoc := "protoc" + EXE
 
-	if err := exec.Command(protoc).Run(); err != nil {
+	if _, err := exec.LookPath(protoc); err != nil {
 		fmt.Println("Make sure that you have `" + protoc + "` in your system or current path, please visit https://github.com/protocolbuffers/protobuf/releases")
 		os.Exit(1)
 	}