lock 323 B

123456789101112131415
  1. #!/bin/sh
  2. # lock screen and take care of related things
  3. # turn off display
  4. xset dpms force off
  5. # disable battery status line
  6. pkill -SIGKILL xbattmon
  7. # lock screen and show battery status again
  8. slock xbattmon
  9. # Show mugshot and save it if present
  10. [ -f ~/slock.jpg ] && meh ~/slock.jpg && mv ~/slock.jpg ~/slock-last.jpg