Skip to content

Commit cd09f22

Browse files
committed
version ID as args
1 parent 00d3ca2 commit cd09f22

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

etc/perf-pr-comment.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@
55
set -eux
66

77
pushd ./internal/cmd/perfcomp >/dev/null || exist
8-
GOWORK=off go run .
8+
GOWORK=off go run . ${VERSION_ID}
99
popd >/dev/null

internal/cmd/perfcomp/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ func main() {
9797
log.Panic("PERF_URI_PRIVATE_ENDPOINT env variable is not set")
9898
}
9999

100-
version := os.Getenv("VERSION_ID")
100+
version := os.Args[len(os.Args)-1]
101101
if version == "" {
102-
log.Panic("VERSION_ID env variable is not set")
102+
log.Panic("could not get VERSION_ID")
103103
}
104104

105105
client, err1 := mongo.Connect(options.Client().ApplyURI(uri))

0 commit comments

Comments
 (0)