diff options
Diffstat (limited to '.forgejo/cascading-pr-runner')
-rwxr-xr-x | .forgejo/cascading-pr-runner | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/.forgejo/cascading-pr-runner b/.forgejo/cascading-pr-runner new file mode 100755 index 0000000..bcb29c6 --- /dev/null +++ b/.forgejo/cascading-pr-runner @@ -0,0 +1,18 @@ +#!/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 |