insidegui / WWDC

The unofficial WWDC app for macOS
https://wwdc.io
BSD 2-Clause "Simplified" License
8.63k stars 783 forks source link

Limit downloads folder recursion, add warnings (Closes #584) #597

Closed insidegui closed 4 years ago

insidegui commented 4 years ago

This addresses the issue that caused hangs when a downloads folder had a deeply nested hierarchy of files.

I've implemented both the suggestion by @allenhumphreys to limit recursion, but I've also added some warnings to the UI when changing folders.

If the user tries to set the downloads folder to a folder that has more than 3 files inside of it (3 was randomly chosen as a threshold for "is this folder empty enough?"), there will be a warning:

Screen Shot 2020-05-27 at 18 02 39

If the user tries to do something really stupid, such as using the home directory or / as the downloads folder, the app will prevent it:

Screen Shot 2020-05-27 at 18 06 58