mirror of
https://github.com/arthur-pbty/arthur-os.git
synced 2026-08-01 20:28:16 +02:00
* Split fido2 and fingerprint setups into setup and remove Don't make one thing do two things * Extract helpers and clean up * No need to hide them * Don't need these
38 lines
1.2 KiB
Bash
Executable File
38 lines
1.2 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
# omarchy:summary=Remove fingerprint authentication from sudo, polkit, and lock screen
|
|
# omarchy:requires-sudo=true
|
|
|
|
set -e
|
|
|
|
|
|
remove_pam_config() {
|
|
# Remove from sudo
|
|
if grep -q pam_fprintd.so /etc/pam.d/sudo; then
|
|
omarchy-echo-info "Removing fingerprint authentication from sudo..."
|
|
sudo sed -i '/pam_fprintd\.so/d' /etc/pam.d/sudo
|
|
fi
|
|
|
|
# Remove from polkit
|
|
if [[ -f /etc/pam.d/polkit-1 ]] && grep -Fq 'pam_fprintd.so' /etc/pam.d/polkit-1; then
|
|
omarchy-echo-info "Removing fingerprint authentication from polkit..."
|
|
sudo sed -i '/pam_fprintd\.so/d' /etc/pam.d/polkit-1
|
|
fi
|
|
}
|
|
|
|
remove_hyprlock_fingerprint_icon() {
|
|
omarchy-echo-info "Removing fingerprint icon from hyprlock placeholder text..."
|
|
sed -i 's/placeholder_text = .*/placeholder_text = Enter Password/' ~/.config/hypr/hyprlock.conf
|
|
sed -i 's/fingerprint:enabled = .*/fingerprint:enabled = false/' ~/.config/hypr/hyprlock.conf
|
|
}
|
|
|
|
omarchy-echo-success "Removing fingerprint scanner from authentication.\n"
|
|
|
|
remove_pam_config
|
|
remove_hyprlock_fingerprint_icon
|
|
|
|
omarchy-echo-info "Removing fingerprint packages..."
|
|
omarchy-pkg-drop fprintd libfprint-git
|
|
|
|
omarchy-echo-success "Fingerprint authentication has been completely removed."
|