Skip to content

Job condition for each Xth run in a workflow or every Xth day of week #26338

Answered by pd185112
pd185112 asked this question in Actions
Discussion options

You must be logged in to vote

actually, you can do multiple cron jobs:
on:
schedule:
# Trigger the nightly build workflow
- cron: ‘0 0 * * *’
# Trigger the weekly build workflow
- cron: ‘0 3 * * 0’

and subsequently run desired jobs with appropriate condition:
test_performance:

# Weekly performance test job
 if: github.event_name == 'schedule' && github.event.schedule == '0 3 * * 0'

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
1 participant