cyp icon indicating copy to clipboard operation
cyp copied to clipboard

Support deleting downloaded YouTube items

Open stuporglue opened this issue 4 years ago • 6 comments

It would be nice if there were a way to delete downloaded YouTube items.

My users can access cyp through the web, but don't have disk access to manage files.

I think this could/should only apply to YouTube files. Since cyp is responsible for downloading them, I see no problem with it also having permissions to delete them.

stuporglue avatar Feb 26 '22 21:02 stuporglue

Hmm, this might be pretty complex. We have no (UI) way of listing contents of the _youtube directory. One could argue that this directory shall be available via the MPD library, but there are no guarantees about its name and/or location within the MPD library structure.

ondras avatar Feb 27 '22 22:02 ondras

No problem to mark this as a "won't fix" issue then. I thought it might be (relatively) simple since everything downloads to the _youtube directory, but since there's no existing code to do directory listings etc. it might be too much work to be worth it.

stuporglue avatar Feb 27 '22 23:02 stuporglue

There is also the option of adding a URL to mpd. When calling youtube-dl --yes-playlist -i -c -x -q -g <URL> yout get back an URL that can be added to MPD via addid command to stream directly.

Thus one could leave the download-folder alone completely.

What do you think?

rominator1983 avatar Nov 28 '23 18:11 rominator1983

There is also the option of adding a URL to mpd. When calling youtube-dl --yes-playlist -i -c -x -q -g <URL> yout get back an URL that can be added to MPD via addid command to stream directly.

Interesting. Is youtube-dl still alive and kicking? Based on my experience, it stopped working quite some time ago, paving the way for more recent alternatives such as https://github.com/yt-dlp/yt-dlp

ondras avatar Nov 28 '23 18:11 ondras

That is true of course. Though most things work when switching to yt-dlp by changing only the command line (this can be done with cyp too) since command line switches seem to be compatible. Interestingly enough the -g switch which makes it extract an audio stream URL is not even documented in yt-dlp but works nonetheless.

rominator1983 avatar Nov 28 '23 19:11 rominator1983

Have played around a little. The switch -g is there but it's not work for longer media any more. At least for YouTube. Other sites might work still. I think at the time of the first ad it breaks and playback stops. Might still work with a premium account.

rominator1983 avatar Jan 27 '24 09:01 rominator1983