Skip to content

Commit 9ea769e

Browse files
authored
Merge pull request #15 from gitgitgadget-workflows/fix-keepalive-in-forks
Fix keepalive in forks
2 parents 039ebd7 + 580b58a commit 9ea769e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.github/workflows/keepalive.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
id: merge
2222
if: github.event.repository.fork == true
2323
run: |
24+
git fetch --unshallow origin &&
2425
git fetch https://github.com/gitgitgadget/gitgitgadget-workflows HEAD &&
2526
if test 0 = $(git rev-list --count HEAD..FETCH_HEAD)
2627
then
@@ -32,7 +33,8 @@ jobs:
3233
id: commit
3334
if: steps.merge.outputs.result != 'merged'
3435
run: |
35-
if test 0 -lt $(git rev-list --count --since=3.weeks.ago HEAD)
36+
if test workflow_dispatch != '${{ github.event_name }}' &&
37+
test 0 -lt $(git rev-list --count --since=3.weeks.ago HEAD)
3638
then
3739
echo "::notice::No need to keep alive, there were commits in the last three weeks"
3840
echo "result=skip-push" >>$GITHUB_OUTPUT

0 commit comments

Comments
 (0)