mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-08-25 21:31:55 +00:00
- Wait for build before publishing to PyPI - Do not run `meta_files` job if release is cancelled - Customizable channel in release workflow - Display badges above changelog Authored by: bashonly, Grub4K
53 lines
1.2 KiB
YAML
53 lines
1.2 KiB
YAML
name: Release (nightly)
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
paths:
|
|
- "yt_dlp/**.py"
|
|
- "!yt_dlp/version.py"
|
|
concurrency:
|
|
group: release-nightly
|
|
cancel-in-progress: true
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
prepare:
|
|
if: vars.BUILD_NIGHTLY != ''
|
|
runs-on: ubuntu-latest
|
|
outputs:
|
|
version: ${{ steps.get_version.outputs.version }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Get version
|
|
id: get_version
|
|
run: |
|
|
python devscripts/update-version.py "$(date -u +"%H%M%S")" | grep -Po "version=\d+(\.\d+){3}" >> "$GITHUB_OUTPUT"
|
|
|
|
build:
|
|
needs: prepare
|
|
uses: ./.github/workflows/build.yml
|
|
with:
|
|
version: ${{ needs.prepare.outputs.version }}
|
|
channel: nightly
|
|
permissions:
|
|
contents: read
|
|
packages: write # For package cache
|
|
secrets:
|
|
GPG_SIGNING_KEY: ${{ secrets.GPG_SIGNING_KEY }}
|
|
|
|
publish:
|
|
needs: [prepare, build]
|
|
uses: ./.github/workflows/publish.yml
|
|
secrets:
|
|
ARCHIVE_REPO_TOKEN: ${{ secrets.ARCHIVE_REPO_TOKEN }}
|
|
permissions:
|
|
contents: write
|
|
with:
|
|
channel: nightly
|
|
prerelease: true
|
|
version: ${{ needs.prepare.outputs.version }}
|
|
target_commitish: ${{ github.sha }}
|