Skip to content

Instantly share code, notes, and snippets.

@vahit
vahit / i3lock_photo.sh
Created August 14, 2017 04:27
Take a photo with webcam if someone insert the wrong passwd -- For i3lock (you need fswebcam!)
echo " " > /tmp/i3lock_log.txt ##clear log
_date()
{
date=`grep 'pam_unix(i3lock:auth): authentication failure' /tmp/i3lock_log.txt | awk {'print $3'} | tail -n 1`
}
_date
pht="0"