Skip to content

Commit 8b502cc

Browse files
authored
ci: update nightly release
1 parent ce98bf0 commit 8b502cc

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.github/workflows/nightly-release.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,24 @@ on:
44
- cron: '0 0 * * *'
55
workflow_dispatch: {}
66
jobs:
7+
check-date:
8+
name: Check dates
9+
runs-on: ubuntu-latest
10+
outputs:
11+
should-run: ${{ steps.code-change.outputs.should-run }}
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v2
15+
- name: Check if code has changed with 24 hours
16+
continue-on-error: true
17+
id: code-change
18+
run: |
19+
[[ $(git rev-list --after="24 hours" --first-parent HEAD) ]] && echo "::set-output name=should-run::true"
720
build-release:
821
name: Build and release Docker image
922
runs-on: ubuntu-latest
23+
needs: check-date
24+
if: needs.check-date.outputs.should-run == 'true'
1025
steps:
1126
- name: Checkout repository
1227
uses: actions/checkout@v2

0 commit comments

Comments
 (0)