Hacker News new | ask | show | jobs
by numpad0 859 days ago
I see lots of yt-dlp commands here so…

PSA: yt-dlp exits non-zero if destination filename or any of intermediate files’ names are too long for the filesystem. Use `-o "%(title).150B [%(id)s].%(ext)s"` to limit filename length(to 150 bytes in this example). “--trim-filenames” don’t work.

1 comments

to whom it may be useful

- `.` - precision flag [1]

- `150` - precision amount [2] - bytes to count after casting to binary representation

- `B` - special conversion type [3] - bytes

[1]: https://docs.python.org/3/library/stdtypes.html#printf-style...

[2]: https://docs.python.org/3/library/stdtypes.html#printf-style...

[3]: https://github.com/yt-dlp/yt-dlp?tab=readme-ov-file#output-t...