boramalper / himawaripy

Set near-realtime picture of Earth as your desktop background
http://labs.boramalper.org/himawaripy
MIT License
1.62k stars 239 forks source link

Added function callback for each DE. #36

Closed narhen closed 8 years ago

narhen commented 8 years ago

I suspect this pull request might be a bit controversial but, in my opinion, main() is a bit cluttered with the way commands for each different DE is executed. As time progresses and changes are made to different versions of DEs, it seems likely that versions will need to be checked in order to execute the correct command for specific versions of the same DE. This will leave main() even more cluttered and messy.

By moving this functionality away from main() and into different functions for each DE, it cleans up main() quite a bit, making the code easier to read, adding support for more DEs very simple, and maintaining support for each DE easy.

boramalper commented 8 years ago

I do agree that (not just main() but the whole) project is getting cluttered with the commands, but I don't see an advantage of encapsulating (mostly) single call() calls under a function. I think it's still, or even gets more cluttered by doing so.

But I'm planning to create a new package, or at least a function, to change the desktop background.