default: true
type: boolean
origin:
- description: .
+ description: Origin
required: false
- default: ''
+ default: 'current repo'
type: choice
options:
- - ''
+ - 'current repo'
permissions:
contents: read
- name: Process origin
id: process_origin
run: |
- echo "origin=${{ inputs.origin || github.repository }}" >> "$GITHUB_OUTPUT"
+ echo "origin=${{ inputs.origin == 'current repo' && github.repository || inputs.origin }}" | tee "$GITHUB_OUTPUT"
unix:
needs: process
run: |
unset LD_LIBRARY_PATH # Harmful; set by setup-python
conda activate build
- python pyinst.py --onedir
+ python -m bundle.pyinstaller --onedir
(cd ./dist/yt-dlp_linux && zip -r ../yt-dlp_linux.zip .)
- python pyinst.py
+ python -m bundle.pyinstaller
mv ./dist/yt-dlp_linux ./yt-dlp_linux
mv ./dist/yt-dlp_linux.zip ./yt-dlp_linux.zip
apt -y install zlib1g-dev python3.8 python3.8-dev python3.8-distutils python3-pip
python3.8 -m pip install -U pip setuptools wheel
# Cannot access requirements.txt from the repo directory at this stage
- python3.8 -m pip install -U Pyinstaller mutagen pycryptodomex websockets brotli certifi
+ python3.8 -m pip install -U Pyinstaller mutagen pycryptodomex websockets brotli certifi secretstorage
run: |
cd repo
- python3.8 -m pip install -U Pyinstaller -r requirements.txt # Cached version may be out of date
+ python3.8 -m pip install -U Pyinstaller secretstorage -r requirements.txt # Cached version may be out of date
python3.8 devscripts/update-version.py -c "${{ inputs.channel }}" -r "${{ needs.process.outputs.origin }}" "${{ inputs.version }}"
python3.8 devscripts/make_lazy_extractors.py
- python3.8 pyinst.py
+ python3.8 -m bundle.pyinstaller
if ${{ vars.UPDATE_TO_VERIFICATION && 'true' || 'false' }}; then
arch="${{ (matrix.architecture == 'armv7' && 'armv7l') || matrix.architecture }}"
python3 devscripts/make_lazy_extractors.py
- name: Build
run: |
- python3 pyinst.py --target-architecture universal2 --onedir
+ python3 -m bundle.pyinstaller --target-architecture universal2 --onedir
(cd ./dist/yt-dlp_macos && zip -r ../yt-dlp_macos.zip .)
- python3 pyinst.py --target-architecture universal2
+ python3 -m bundle.pyinstaller --target-architecture universal2
- name: Verify --update-to
if: vars.UPDATE_TO_VERIFICATION
python3 devscripts/make_lazy_extractors.py
- name: Build
run: |
- python3 pyinst.py
+ python3 -m bundle.pyinstaller
mv dist/yt-dlp_macos dist/yt-dlp_macos_legacy
- name: Verify --update-to
python devscripts/make_lazy_extractors.py
- name: Build
run: |
- python setup.py py2exe
+ python -m bundle.py2exe
Move-Item ./dist/yt-dlp.exe ./dist/yt-dlp_min.exe
- python pyinst.py
- python pyinst.py --onedir
+ python -m bundle.pyinstaller
+ python -m bundle.pyinstaller --onedir
Compress-Archive -Path ./dist/yt-dlp/* -DestinationPath ./dist/yt-dlp_win.zip
- name: Verify --update-to
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
- with: # 3.7 is used for Vista support. See https://github.com/yt-dlp/yt-dlp/issues/390
- python-version: "3.7"
+ with:
+ python-version: "3.8"
architecture: "x86"
- name: Install Requirements
run: |
python devscripts/make_lazy_extractors.py
- name: Build
run: |
- python pyinst.py
+ python -m bundle.pyinstaller
- name: Verify --update-to
if: vars.UPDATE_TO_VERIFICATION
run: |
cat >> _update_spec << EOF
# This file is used for regulating self-update
- lock 2022.08.18.36 .+ Python 3.6
+ lock 2022.08.18.36 .+ Python 3\.6
+ lock 2023.11.16 (?!win_x86_exe).+ Python 3\.7
+ lock 2023.11.16 win_x86_exe .+ Windows-(?:Vista|2008Server)
+ lockV2 yt-dlp/yt-dlp 2022.08.18.36 .+ Python 3\.6
+ lockV2 yt-dlp/yt-dlp 2023.11.16 (?!win_x86_exe).+ Python 3\.7
+ lockV2 yt-dlp/yt-dlp 2023.11.16 win_x86_exe .+ Windows-(?:Vista|2008Server)
+ lockV2 yt-dlp/yt-dlp-nightly-builds 2023.11.15.232826 (?!win_x86_exe).+ Python 3\.7
+ lockV2 yt-dlp/yt-dlp-nightly-builds 2023.11.15.232826 win_x86_exe .+ Windows-(?:Vista|2008Server)
+ lockV2 yt-dlp/yt-dlp-master-builds 2023.11.15.232812 (?!win_x86_exe).+ Python 3\.7
+ lockV2 yt-dlp/yt-dlp-master-builds 2023.11.15.232812 win_x86_exe .+ Windows-(?:Vista|2008Server)
EOF
- name: Sign checksum files