#!/bin/bash set -ex runner=$1 runner_pr=$2 act=$3 act_pr=$4 url=$(jq --raw-output .head.repo.html_url < $act_pr) test "$url" != null url=${url##http*://} branch=$(jq --raw-output .head.ref < $act_pr) test "$branch" != null cd $runner sed -i -e "s|^replace github.com/nektos/act.*|replace github.com/nektos/act => $url $branch|" go.mod GOPROXY=direct go mod tidy date > last-upgrade