Set up a weekly release train
A release train is a weekly rule, for example "every Tuesday at 22:00 merge the open pull request from release into prod". You set it once. It is on Pro.
Set it up
- Open Settings, find the repository, and press Add a train.
- Choose the branch the pull request comes from and the branch it merges into.
- Pick the days, the time and your time zone.
- Choose how early it should schedule the merge and email you: 15, 30 or 60 minutes before.
What happens each week
- Before the time, it looks for the one open pull request from your branch into the other.
- It schedules that pull request like any other release: the commit is pinned, prechecks run again at merge time, the deploy is watched and a failed deploy is reverted if you turned auto-revert on.
- It emails you and the notify list with a link, so you can cancel it before it goes out.
When it does nothing
- There is no open pull request from that branch, or more than one. It cannot tell which to merge, so it schedules nothing and emails you why.
- The service was down and there was no time left to warn you. It is recorded as missed.
- The usual refusals apply: a conflict with another scheduled release, a plan limit, paused merges, or checks that fail at merge time.
Good to know
- The train acts as the person who set it up. If they lose write access on GitHub, the merge is skipped.
- Each run counts as one release on your plan.
- Pause a train from Settings to skip it for now, or remove it. You can have up to three per repository.
- The weekly pull request still needs the reviews and checks your branch rules ask for.
More guides: Schedule your first merge · Set up automatic revert for a failed deploy