def not a good idea I simply because most the time youer not logged in and turning off sleep because sshd is running is wrong. better solution when logged in would be 1 make sure charger pluged, as rainisto said, if using it more than screen timeout.