diff --git a/README.md b/README.md index e32c26e8f..863dd0d82 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,9 @@ jobs: repo-sync: runs-on: ubuntu-latest steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 + with: + persist-credentials: false - name: repo-sync uses: repo-sync/github-sync@v2 with: @@ -64,4 +66,4 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d -This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome! \ No newline at end of file +This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome! diff --git a/github-sync.sh b/github-sync.sh index 8144c2821..57b448c3f 100755 --- a/github-sync.sh +++ b/github-sync.sh @@ -23,7 +23,7 @@ fi echo "UPSTREAM_REPO=$UPSTREAM_REPO" echo "BRANCHES=$BRANCH_MAPPING" -# GitHub actions v2 no longer auto set GITHUB_TOKEN +git config --unset-all http."https://github.com/".extraheader git remote set-url origin "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$GITHUB_REPOSITORY" git remote add tmp_upstream "$UPSTREAM_REPO" git fetch tmp_upstream