2023-03-03 17:03:12 +00:00
|
|
|
name: Release (nightly)
|
|
|
|
on:
|
2023-11-12 23:49:15 +00:00
|
|
|
schedule:
|
|
|
|
- cron: '23 23 * * *'
|
2023-03-03 17:03:12 +00:00
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
jobs:
|
2023-11-12 23:49:15 +00:00
|
|
|
check_nightly:
|
2023-03-03 17:03:12 +00:00
|
|
|
if: vars.BUILD_NIGHTLY != ''
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
outputs:
|
2023-11-12 23:49:15 +00:00
|
|
|
commit: ${{ steps.check_for_new_commits.outputs.commit }}
|
2023-03-03 17:03:12 +00:00
|
|
|
steps:
|
2023-11-13 00:30:01 +00:00
|
|
|
- uses: actions/checkout@v4
|
2023-11-12 23:49:15 +00:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Check for new commits
|
|
|
|
id: check_for_new_commits
|
2023-03-03 17:03:12 +00:00
|
|
|
run: |
|
2024-02-11 13:58:18 +00:00
|
|
|
relevant_files=("yt_dlp/*.py" ':!yt_dlp/version.py' "setup.py" "bundle/*.py")
|
2023-11-12 23:49:15 +00:00
|
|
|
echo "commit=$(git log --format=%H -1 --since="24 hours ago" -- "${relevant_files[@]}")" | tee "$GITHUB_OUTPUT"
|
2023-03-03 17:03:12 +00:00
|
|
|
|
2023-11-12 23:49:15 +00:00
|
|
|
release:
|
|
|
|
needs: [check_nightly]
|
|
|
|
if: ${{ needs.check_nightly.outputs.commit }}
|
|
|
|
uses: ./.github/workflows/release.yml
|
2023-03-03 17:03:12 +00:00
|
|
|
with:
|
2023-11-12 23:49:15 +00:00
|
|
|
prerelease: true
|
|
|
|
source: nightly
|
2023-03-03 17:03:12 +00:00
|
|
|
permissions:
|
|
|
|
contents: write
|
2023-11-12 23:49:15 +00:00
|
|
|
packages: write
|
|
|
|
id-token: write # mandatory for trusted publishing
|
|
|
|
secrets: inherit
|