Skip to content

Commit 4a07d80

Browse files
committed
Correct path to work also with Forgejo
Forgejo does use slightly different path, adapt to it. Signed-off-by: David Heidelberg <david@ixit.cz>
1 parent 2c19ded commit 4a07d80

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

entrypoint.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ fi
3737
echo
3838
echo -e "\e[0;34mGet the list of commits included in the PR($GITHUB_REF).\e[0m"
3939
PR=${GITHUB_REF#"refs/pull/"}
40-
PRNUM=${PR%"/merge"}
40+
PRNUM=${PR%"/merge"} # GitHub
41+
PRNUM=${PR%"/head"} # Forgejo
4142
URL=${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/pulls/${PRNUM}/commits
4243
echo " - API endpoint: $URL"
4344

0 commit comments

Comments
 (0)