Fix resolc-bin push auth (#543)

Pushes to `resolc-bin` 403ed after bumping `actions/checkout` to `v6`
(detected by [failure of the nightly
release](https://github.com/paritytech/revive/actions/runs/27049132601/job/79841157330)).
This PR now passes the app token to the resolc-bin checkout via
[`token:`](https://github.com/actions/checkout/blob/df4cb1c069e1874edd31b4311f1884172cec0e10/README.md?plain=1#L66-L76)
and drops the remote-URL/sed workaround.
This commit is contained in:
LJ authored and GitHub committed 2026-06-06 11:45:35 +02:00
1 parent 229ce55bd6
commit 1e6a631bc0
3 files changed
+23 -41

No files matched your search

+8 -17
View File
@@ -17,13 +17,7 @@ jobs:
with:
path: tmp
- name: Checkout
uses: actions/checkout@v6
with:
repository: paritytech/resolc-bin
path: resolc-bin
- uses: actions/create-github-app-token@v1
- uses: actions/create-github-app-token@v3
id: app-token
with:
app-id: ${{ secrets.REVIVE_JSON_APP_ID }}
@@ -31,12 +25,16 @@ jobs:
owner: paritytech
repositories: resolc-bin
- name: Checkout
uses: actions/checkout@v6
with:
repository: paritytech/resolc-bin
path: resolc-bin
token: ${{ steps.app-token.outputs.token }}
- name: Generate json and push
env:
TOKEN: ${{ steps.app-token.outputs.token }}
APP_NAME: "paritytech-revive-json"
Green: "\e[32m"
NC: "\e[0m"
run: |
sudo apt-get update && sudo apt-get install -y wget
wget https://github.com/${GITHUB_REPOSITORY}/releases/download/${GITHUB_REF_NAME}/resolc-x86_64-unknown-linux-musl
@@ -51,13 +49,6 @@ jobs:
chmod +x ../tmp/.github/scripts/resolc-bin-gh-pages.sh
bash ../tmp/.github/scripts/resolc-bin-gh-pages.sh $PWD
echo "${Green}Add new remote with gh app token${NC}"
git remote set-url origin $(git config remote.origin.url | sed "s/github.com/${APP_NAME}:${TOKEN}@github.com/g")
echo "${Green}Remove http section that causes issues with gh app auth token${NC}"
sed -i.bak '/\[http/d' ./.git/config
sed -i.bak '/extraheader/d' ./.git/config
git config user.email "ci@parity.io"
git config user.name "${APP_NAME}"