Videos: Add "update-yt-dlp" init target to scripts/dist/Makefile #4982

Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
Michael Mayer
2025-06-10 14:22:07 +02:00
parent dc265085a8
commit cf7aaa5059
3 changed files with 6 additions and 1 deletions

View File

@@ -16,7 +16,7 @@ import (
)
const (
testVideoRawURL = "https://youtu.be/fD6VYfy3B2s"
testVideoRawURL = "https://www.youtube.com/watch?v=fD6VYfy3B2s"
playlistRawURL = "https://soundcloud.com/mattheis/sets/kindred-phenomena"
channelRawURL = "https://www.youtube.com/channel/UCHDm-DKoMyJxKVgwGmuTaQA"
subtitlesTestVideoRawURL = "https://www.youtube.com/watch?v=QRS8MkLhQmM"

View File

@@ -38,6 +38,8 @@ func TestDownload(t *testing.T) {
t.Errorf("copy n not equal to download buffer: %d!=%d", n, downloadBuf.Len())
}
t.Logf("error: %s", stderrBuf.String())
if n < 10000 {
t.Errorf("should have copied at least 10000 bytes: %d", n)
}

View File

@@ -61,6 +61,9 @@ darktable:
sudo apt-get update
sudo apt-get install darktable
sudo apt-get autoremove
yt-dlp: update-yt-dlp
update-yt-dlp:
sudo yt-dlp -U
# Declare all targets as "PHONY", see https://www.gnu.org/software/make/manual/html_node/Phony-Targets.html.
MAKEFLAGS += --always-make