-
Notifications
You must be signed in to change notification settings - Fork 0
32 lines (26 loc) · 885 Bytes
/
nightly.yaml
File metadata and controls
32 lines (26 loc) · 885 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Nightly rebuild
on:
schedule:
- cron: "17 3 * * *"
workflow_dispatch:
permissions:
contents: write
jobs:
ensure-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
persist-credentials: true
- name: Force minor bump if no unreleased commits
shell: bash
run: |
set -euo pipefail
git config user.name 'github-actions[bot]'
git config user.email '41898282+github-actions[bot]@users.noreply.github.com'
last_tag="$(git describe --tags --abbrev=0 2>/dev/null || echo '')"
if [ -n "${last_tag}" ] && [ "$(git rev-list "${last_tag}..HEAD" --count)" -eq 0 ]; then
git commit --allow-empty -m 'feat: nightly rebuild to refresh base image and cached actions'
git push origin HEAD:main
fi