Schedule CI daily at 5am to detect code rot early (#7363)

* Schedule CI daily at 5am

* Package but don't upload when cron

* Update ChangeLog

* Comment explaining CI use
This commit is contained in:
Nick Bolton 2024-07-02 16:36:54 +01:00 committed by GitHub
parent c8d9707857
commit f2cc964b3d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 16 additions and 8 deletions

View file

@ -1,3 +1,7 @@
# All-in-one continuous integration (CI) workflow.
# Runs on all platforms (Windows, macOS, and Linux)
# for all events (pull request, release, and schedule).
name: CI
on:
@ -14,10 +18,13 @@ on:
- ready_for_review
release:
types: [published]
schedule:
- cron: "0 5 * * *"
env:
SYNERGY_VERSION: ${{ github.event.inputs.version || github.event.release.tag_name }}
ENABLE_PACKAGING: ${{ !github.event.pull_request.draft }}
PACKAGE_BUILD: ${{ !github.event.pull_request.draft }}
PACKAGE_UPLOAD: ${{ !github.event.pull_request.draft && github.event_name != 'schedule' }}
UPLOAD_TO_GITHUB: ${{ github.event_name == 'pull_request' && !github.event.pull_request.draft }}
UPLOAD_TO_GDRIVE: ${{ github.event_name != 'pull_request' }}
@ -68,14 +75,14 @@ jobs:
run: ./build/bin/unittests
- name: Package
if: ${{ env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_BUILD == 'true' }}
run: python ./scripts/package.py
env:
WINDOWS_PFX_CERTIFICATE: ${{ secrets.WINDOWS_PFX }}
WINDOWS_PFX_PASSWORD: ${{ secrets.WINDOWS_PFX_PASS }}
- name: Upload
if: ${{ env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_UPLOAD == 'true' }}
uses: ./.github/actions/dist-upload
with:
use_github: ${{ env.UPLOAD_TO_GITHUB }}
@ -133,7 +140,7 @@ jobs:
run: ./build/bin/unittests
- name: Package
if: ${{ env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_BUILD == 'true' }}
run: ./scripts/package.py
env:
APPLE_CODESIGN_ID: ${{ secrets.APPLE_CODESIGN_ID }}
@ -144,7 +151,7 @@ jobs:
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
- name: Upload
if: ${{ env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_UPLOAD == 'true' }}
uses: ./.github/actions/dist-upload
with:
use_github: ${{ env.UPLOAD_TO_GITHUB }}
@ -258,14 +265,14 @@ jobs:
run: ./build/bin/unittests
- name: Package
if: ${{ !matrix.distro.skip-package && env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_BUILD == 'true' }}
env:
LINUX_EXTRA_PACKAGES: ${{ matrix.distro.extra-packages }}
LINUX_PACKAGE_USER: ${{ matrix.distro.package-user }}
run: ./scripts/package.py
- name: Upload
if: ${{ !matrix.distro.skip-package && env.ENABLE_PACKAGING == 'true' }}
if: ${{ env.PACKAGE_UPLOAD == 'true' }}
uses: ./.github/actions/dist-upload
with:
use_github: ${{ env.UPLOAD_TO_GITHUB }}

View file

@ -1,7 +1,7 @@
name: "Close stale issues and PRs"
on:
schedule:
- cron: "0 0 * * *"
- cron: "0 5 * * *"
jobs:
stale-issues:

View file

@ -37,6 +37,7 @@ Enhancements:
- #7353 Re-implement packaging for GitHub workflows (macOS)
- #7360 Re-implement packaging for GitHub workflows (Windows)
- #7361 Re-implement packaging for GitHub workflows (Linux)
- #7363 Schedule CI daily at 5am to detect code rot early
# 1.14.6