Skip to content

Commit

Permalink
Merge pull request #97 from coq-community/cron_schedule
Browse files Browse the repository at this point in the history
introduce 'ci_cron_schedule' for scheduled CI actions
  • Loading branch information
Zimmi48 authored Apr 13, 2021
2 parents 6d0eada + 5143846 commit ad871ac
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docker-action.yml.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
name: Docker CI

on:
{{# ci_cron_schedule }}
schedule:
- cron: '{{ ci_cron_schedule }}'
{{/ ci_cron_schedule }}
push:
branches:
- {{branch}}{{^branch}}master{{/branch}}
Expand Down
4 changes: 4 additions & 0 deletions nix-action.yml.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
name: Nix CI

on:
{{# ci_cron_schedule }}
schedule:
- cron: '{{ ci_cron_schedule }}'
{{/ ci_cron_schedule }}
push:
branches:
- {{branch}}{{^branch}}master{{/branch}}
Expand Down
16 changes: 16 additions & 0 deletions ref.yml
Original file line number Diff line number Diff line change
Expand Up @@ -443,3 +443,19 @@ fields:
- .travis.yml
- docker-action.yml
- config.yml
- ci_cron_schedule:
required: false
description: >
Schedule for regular actions-based CI runs (in cron syntax).
The implied time zone is UTC. There is no default value to
keep projects from running their CI all at the same time. See
https://crontab.guru/ for a cron expression generator. You can
use 'echo "$(shuf -i0-59 -n1) $(shuf -i1-5 -n1) * * *"' to
generate a daily schedule starting at a random night-time
minute.
examples:
- '5 4 * * *' #daily at 4:05
- '5 4 * * 0' #at 04:05 on Sunday
used:
- docker-action.yml
- nix-action.yml

0 comments on commit ad871ac

Please sign in to comment.