Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[fix](regression) rm github_token, no need for it #20360

Merged
merged 1 commit into from
Jun 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

usage() {
echo -e "Usage:
env GITHUB_TOKEN=****** bash $0 <PULL_NUMBER> <OPTIONS>
bash $0 <PULL_NUMBER> <OPTIONS>
note: https://github.com/apache/doris/pull/13259, PULL_NUMBER is 13259
OPTIONS should be one of [be-ut|fe-ut|ckb|regression-p0|regression-p1|arm-regression-p0]
" && return 1
Expand All @@ -35,7 +35,6 @@ _get_pr_changed_files() {
OPTIONS can be one of [all|added|modified|removed], default is all
"
if [[ -z "$1" ]]; then echo -e "${usage_str}" && return 1; fi
if [[ -z "${GITHUB_TOKEN}" ]]; then echo "error: GITHUB_TOKEN required..." && return 1; fi
if ! curl --version >/dev/null; then echo 'error: curl required...' && return 1; fi
if ! command -v jq >/dev/null; then sudo yum install jq -y || sudo apt install -y jq; fi

Expand All @@ -49,7 +48,6 @@ _get_pr_changed_files() {
while [[ ${try_times} -gt 0 ]]; do
if curl \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${GITHUB_TOKEN:-}" \
https://api.github.com/repos/"${OWNER}"/"${REPO}"/pulls/"${PULL_NUMBER}"/files?per_page="${per_page}" \
2>/dev/null >"${file_name}"; then
break
Expand Down