Update start.sh

This commit is contained in:
Adam Dobrawy 2019-09-12 03:06:46 +02:00 committed by GitHub
parent 277d92c683
commit e8d06b80fa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,9 +1,9 @@
#!/bin/sh #!/bin/sh
echo "Push to branch ${INPUT_BRANCH}"; echo "Push to branch ${INPUT_BRANCH:=master}";
[ -z "${INPUT_GITHUB_TOKEN}" ] && { [ -z "${INPUT_GITHUB_TOKEN}" ] && {
echo 'Missing input "github_token: ${{ secrets.GITHUB_TOKEN }}".'; echo 'Missing input "github_token: ${{ secrets.GITHUB_TOKEN }}".';
exit 1; exit 1;
}; };
header=$(echo -n "ad-m:${INPUT_GITHUB_TOKEN}" | base64) header=$(echo -n "ad-m:${INPUT_GITHUB_TOKEN}" | base64)
git -c http.extraheader="AUTHORIZATION: basic $header" push origin HEAD:master; git -c http.extraheader="AUTHORIZATION: basic $header" push origin HEAD:${INPUT_BRANCH};