Skip to content

Commit

Permalink
Fix docs
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Sverdlov <[email protected]>
  • Loading branch information
sverdlov93 committed Aug 20, 2023
1 parent 0d4f499 commit 653b9eb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions build/utils/npm.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ func runNpmLsWithNodeModules(executablePath, srcPath string, npmArgs []string, l
log.Warn(err.Error())
}
if len(errData) > 0 {
log.Warn("Encountered some issues while running 'npm ls' command:\n" + string(errData))
log.Warn("Encountered some issues while running 'npm ls' command:\n" + strings.TrimSpace(string(errData)))
}
return
}
Expand All @@ -148,7 +148,7 @@ func runNpmLsWithoutNodeModules(executablePath, srcPath string, npmArgs []string
log.Warn(err.Error())
}
if len(errData) > 0 {
log.Warn("Encountered some issues while running 'npm ls' command:\n" + string(errData))
log.Warn("Encountered some issues while running 'npm ls' command:\n" + strings.TrimSpace(string(errData)))
}
return data, nil
}
Expand Down Expand Up @@ -487,7 +487,7 @@ func GetNpmConfigCache(srcPath, executablePath string, npmArgs []string, log uti
data, errData, err := RunNpmCmd(executablePath, srcPath, AppendNpmCommand(append(npmArgs, "--json=false"), "config"), log)
// Some warnings and messages of npm are printed to stderr. They don't cause the command to fail, but we'd want to show them to the user.
if len(errData) > 0 {
log.Warn("error while running the command '" + executablePath + " " + strings.Join(npmArgs, " ") + "' :\n" + string(errData))
log.Warn("Encountered some issues while running 'npm get cache' command:\n" + string(errData))
}
if err != nil {
return "", err
Expand Down

0 comments on commit 653b9eb

Please sign in to comment.