Skip to content

Commit

Permalink
Fix broken login
Browse files Browse the repository at this point in the history
  • Loading branch information
jkmassel committed Aug 20, 2021
1 parent 7ebbd4b commit 5173201
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion bin/comment_on_pr
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
#!/bin/bash -eu

PR_MESSAGE_FILE=$1
GITHUB_TOKEN=$2

if ! command -v gh &> /dev/null; then
brew install gh
fi

gh auth login
FILENAME="/tmp/github-token-$BUILDKITE_BUILD_ID"
echo $GITHUB_TOKEN > $FILENAME

gh auth login --with-token < $FILENAME
gh pr comment --body-file $PR_MESSAGE_FILE

0 comments on commit 5173201

Please sign in to comment.