fix windows bug

master
kingxt 4 years ago
parent d117e31993
commit 19888b7d11

@ -28,6 +28,9 @@ func getParentPackage(dir string) (string, error) {
var tempPath = absDir var tempPath = absDir
var hasGoMod = false var hasGoMod = false
for { for {
if tempPath == filepath.Dir(tempPath) {
break
}
tempPath = filepath.Dir(tempPath) tempPath = filepath.Dir(tempPath)
if goctlutil.FileExists(filepath.Join(tempPath, goModeIdentifier)) { if goctlutil.FileExists(filepath.Join(tempPath, goModeIdentifier)) {
tempPath = filepath.Dir(tempPath) tempPath = filepath.Dir(tempPath)

Loading…
Cancel
Save