From aab74f8f63ab9923a0f6149f982edd6fab25502f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=B1=B3?= Date: Sat, 14 Dec 2024 15:30:51 +0800 Subject: [PATCH] update --- .github/workflows/DDTV_Test.yml | 49 +++++++++++++++++++++++++++------ 1 file changed, 40 insertions(+), 9 deletions(-) diff --git a/.github/workflows/DDTV_Test.yml b/.github/workflows/DDTV_Test.yml index 9d9187d6..2b1ea4e1 100644 --- a/.github/workflows/DDTV_Test.yml +++ b/.github/workflows/DDTV_Test.yml @@ -180,11 +180,22 @@ jobs: run: cp -r Static Server/build_output/Static - - name: Copy ffmpeg.exe (Windows) + - name: Download ffmpeg.exe (Windows) if: matrix.os == 'windows-latest' run: | - mkdir Server/build_output/Plugins/Plugins/ffmpeg - copy Server/Plugins/ffmpeg/ffmpeg.exe Server/build_output/Plugins/Plugins/ffmpeg/ffmpeg.exe + curl -L -o ffmpeg.zip https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-master-latest-win64-gpl.zip + tar -xf ffmpeg.zip --directory Server/build_output/Plugins/Plugins/ffmpeg --strip-components=1 ffmpeg-master-latest-win64-gpl/bin/ffmpeg.exe + + - name: Verify ffmpeg.exe + if: matrix.os == 'windows-latest' + run: | + if [ -f "Server/build_output/Plugins/Plugins/ffmpeg/ffmpeg.exe" ]; then + echo "ffmpeg.exe downloaded and extracted successfully." + else + echo "Failed to download and extract ffmpeg.exe." + exit 1 + fi + - name: Move all files to bin folder and create shortcut (Linux or macOS) if: runner.os != 'Windows' @@ -350,11 +361,21 @@ jobs: - name: Copy Static folder to build_output run: cp -r Static Desktop/build_output/Static - - name: Copy ffmpeg.exe (Windows) + - name: Download ffmpeg.exe (Windows) + if: matrix.os == 'windows-latest' + run: | + curl -L -o ffmpeg.zip https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-master-latest-win64-gpl.zip + tar -xf ffmpeg.zip --directory Server/build_output/Plugins/Plugins/ffmpeg --strip-components=1 ffmpeg-master-latest-win64-gpl/bin/ffmpeg.exe + + - name: Verify ffmpeg.exe if: matrix.os == 'windows-latest' run: | - mkdir Desktop\\build_output\\Plugins\\ffmpeg - copy Desktop\\Plugins\\ffmpeg\\ffmpeg.exe Desktop\\build_output\\Plugins\\ffmpeg\\ffmpeg.exe + if [ -f "Server/build_output/Plugins/Plugins/ffmpeg/ffmpeg.exe" ]; then + echo "ffmpeg.exe downloaded and extracted successfully." + else + echo "Failed to download and extract ffmpeg.exe." + exit 1 + fi - name: Copy VLC (Windows) if: runner.os == 'Windows' @@ -498,11 +519,21 @@ jobs: - name: Copy Static folder to build_output run: cp -r Static Client/build_output/Static - - name: Copy ffmpeg.exe (Windows) + - name: Download ffmpeg.exe (Windows) + if: matrix.os == 'windows-latest' + run: | + curl -L -o ffmpeg.zip https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-master-latest-win64-gpl.zip + tar -xf ffmpeg.zip --directory Server/build_output/Plugins/Plugins/ffmpeg --strip-components=1 ffmpeg-master-latest-win64-gpl/bin/ffmpeg.exe + + - name: Verify ffmpeg.exe if: matrix.os == 'windows-latest' run: | - mkdir Client\\build_output\\Plugins\\ffmpeg - copy Client\\Plugins\\ffmpeg\\ffmpeg.exe Client\\build_output\\Plugins\\ffmpeg\\ffmpeg.exe + if [ -f "Server/build_output/Plugins/Plugins/ffmpeg/ffmpeg.exe" ]; then + echo "ffmpeg.exe downloaded and extracted successfully." + else + echo "Failed to download and extract ffmpeg.exe." + exit 1 + fi - name: Move all files to bin folder and create shortcut (Windows) if: runner.os == 'Windows'