mirror of
https://github.com/basecamp/omarchy.git
synced 2025-07-27 12:19:24 +00:00
Only allow fingerprint setup if a sensor is detected
This commit is contained in:
@ -1,7 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
yay -S --noconfirm --needed fprintd libfprint
|
||||
yay -S --noconfirm --needed fprintd libfprint lsusb
|
||||
|
||||
if ! lsusb | grep -iq fingerprint; then
|
||||
echo "No fingerprint sensor detected."
|
||||
else
|
||||
# Add fingerprint authentication as an option for sudo
|
||||
if ! grep -q pam_fprintd.so /etc/pam.d/sudo; then
|
||||
sudo sed -i '1i auth sufficient pam_fprintd.so' /etc/pam.d/sudo
|
||||
@ -32,3 +35,4 @@ if fprintd-verify; then
|
||||
else
|
||||
echo -e "\e[31m\nSomething went wrong. Maybe try again?\e[0m"
|
||||
fi
|
||||
fi
|
||||
|
Reference in New Issue
Block a user