We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f018695 commit 702c22bCopy full SHA for 702c22b
1 file changed
go/extractor/cli/go-autobuilder/go-autobuilder.go
@@ -350,8 +350,7 @@ func main() {
350
log.Printf("Autobuilder was built with %s, environment has %s\n", runtime.Version(), getEnvGoVersion())
351
352
srcdir := os.Getenv("LGTM_SRC")
353
- inLGTM := srcdir != ""
354
- if inLGTM {
+ if srcdir != "" {
355
log.Printf("LGTM_SRC is %s\n", srcdir)
356
} else {
357
cwd, err := os.Getwd()
@@ -399,9 +398,7 @@ func main() {
399
398
importpath := getImportPath()
400
needGopath := getNeedGopath(depMode, importpath)
401
402
- if os.Getenv("LGTM_INDEX_NEED_GOPATH") != "" {
403
- inLGTM = true
404
- }
+ inLGTM := os.Getenv("LGTM_SRC") != "" || os.Getenv("LGTM_INDEX_NEED_GOPATH") != ""
405
406
if inLGTM && needGopath {
407
// a temporary directory where everything is moved while the correct
0 commit comments