fix: updater does not work on main branch (#12537)

Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>

Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
This commit is contained in:
Huáng Jùnliàng 2020-12-21 17:06:15 -05:00 committed by GitHub
parent 0f866ed9d2
commit bb2343aba4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -47,7 +47,7 @@ jobs:
- name: Commit changes - name: Commit changes
run: | run: |
git config user.name "Babel Bot" git config user.name "Babel Bot"
git config user.email "Babel Bot <babel-bot@users.noreply.github.com>" git config user.email "babel-bot@users.noreply.github.com"
git checkout -b update-test262-parser git checkout -b update-test262-parser
git commit -am "chore: update test262 to ${{ steps.test262.outputs.sha1 }}" git commit -am "chore: update test262 to ${{ steps.test262.outputs.sha1 }}"
git push --force origin update-test262-parser git push --force origin update-test262-parser
@ -56,7 +56,7 @@ jobs:
with: with:
github-token: ${{ secrets.BOT_TOKEN }} github-token: ${{ secrets.BOT_TOKEN }}
script: | script: |
const base = process.env.GITHUB_REF.replace("/ref/heads/", ""); const base = process.env.GITHUB_REF.replace("refs/heads/", "");
const { data: prs } = await github.pulls.list({ const { data: prs } = await github.pulls.list({
owner: context.repo.owner, owner: context.repo.owner,
repo: context.repo.repo, repo: context.repo.repo,