bit-team / backintime

Back In Time - An easy-to-use backup tool for GNU Linux using rsync in the back
https://backintime.readthedocs.io
GNU General Public License v2.0
1.9k stars 175 forks source link

#1268 Added sleep mode feature #1752

Closed FanisBak closed 3 weeks ago

FanisBak commented 3 weeks ago

1268

I tried to create sleep mode for the Back in Time application. I also added a button on the GUI of the app. This is my first contribution so I hope I did well. Any feedback would be helpful.

buhtz commented 3 weeks ago

Hello Fanis, On behalf of the team, thank you for your contribution and taking the time to improve Back In Time. We appreciate it.

As I remember your contribution is part of something like a school home work, isn't it? Do you have a deadline or something?

Your PR is of good quality on a first look. But the behavior/feature is complex so will need some time to test and improve the PR:

Without reviewing it in detail yet please let me add some first impressions and questions.

EDIT: I don't know much about DBus and also doesn't have much experience with it. Do you have? The fixed dictionary DBUS_SLEEP doesn't feel to me as an elegant solution. Might it better to use Introspection to determine the the correct DBus Service/Name/Object/Method (e.g. StackOverflow question). To me it is also not clear if that names are different between the GNU Linux distributions and their desktop environments. It sounds complex but possible. I suggest to make an extra PR for the determine-suspend-mode-trigger-on-DBus-feature and put this current PR on hold.

Best, Christian

buhtz commented 3 weeks ago

Follow-up #1757