scripts/sync_makefiles.sh: redirect git-push to /dev/null (#5478)

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
This commit is contained in:
Simon Pasquier 2019-04-18 12:01:49 +02:00 committed by GitHub
parent 95193fa027
commit 7efb8e9480
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -58,8 +58,8 @@ curl --retry 5 --silent -u "${git_user}:${GITHUB_TOKEN}" https://api.github.com/
git config user.name "${git_user}"
git add .
git commit -s -m "${commit_msg}"
# stderr is redirected to /dev/null otherwise git-push could leak the token in the logs.
if git push --quiet "https://${GITHUB_TOKEN}:@github.com/${org}/${repo}" --set-upstream "${branch}" 2>/dev/null; then
# stdout and stderr are redirected to /dev/null otherwise git-push could leak the token in the logs.
if git push --quiet "https://${GITHUB_TOKEN}:@github.com/${org}/${repo}" --set-upstream "${branch}" 1>/dev/null 2>&1; then
curl --show-error --silent \
-u "${git_user}:${GITHUB_TOKEN}" \
-X POST \