zrhoffman commented on code in PR #7226:
URL: https://github.com/apache/trafficcontrol/pull/7226#discussion_r1036557410


##########
.github/actions/go-test/entrypoint.sh:
##########
@@ -34,9 +34,7 @@ if [ -z "$INPUT_DIR" ]; then
 fi
 
 # Need to fetch golang.org/x/* dependencies
-if ! [ -d "${GITHUB_WORKSPACE}/vendor/golang.org" ]; then
-       go mod vendor
-fi
+go mod vendor -v

Review Comment:
   That condition is there in case someone wants to test 
`.github/actions/go-test/entrypoint.sh` locally without getting their modules 
wiped out and replaced each time.
   
   What we should really be doing is using the 
[`actions/setup-go`](https://github.com/actions/setup-go#caching-dependency-files-and-build-outputs)
 action with `cache: true` to install Go, which would handle dependency caching 
for us (and would run `go mod vendor` itself.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to