JannikHv / gydl

gydl (Graphical YouTube-Download) is a GUI wrapper around yt-dlp.
GNU General Public License v2.0
151 stars 22 forks source link

Use appropriate xdg user directory #10

Closed AsavarTzeth closed 7 years ago

AsavarTzeth commented 7 years ago

Files that are downloaded should not simply be dumped in the user home directory. The appropriate location is the xdg user download directory.

See: https://www.freedesktop.org/wiki/Software/xdg-user-dirs/

Some Pros of new behavior:

This also fits the Flatpak sand-boxing model. With the old behavior a user would find the files under ~/.var/app/com.github.JannikHv.Gydl, which would be less user friendly. However Flatpak allows granting access to specific xdg user directories, which would work well with this change.

In the end, a lot of people would probably prefer a user specified location. However because of the planned rewrite, a smaller fix like this that will most likely cover the majority of users is a good compromise.

AsavarTzeth commented 7 years ago

By the way, I was unsure what style to use for the variable name, since it seems to vary a lot. I hope it is to your satisfaction.

AsavarTzeth commented 7 years ago

Thanks a bunch for the merge! That is all from me. Now all I need is that svg icon followed by a release, then I can add this to flathub. No rush though :)