mirror of
https://github.com/ItsDrike/dotfiles.git
synced 2025-02-24 04:09:03 +00:00
Auto-start bluetooth service on toggle if not running
This commit is contained in:
parent
f76f7c65da
commit
d4dad7beff
1 changed files with 4 additions and 0 deletions
|
@ -11,6 +11,10 @@ toggle() {
|
|||
rfkill block bluetooth
|
||||
else
|
||||
rfkill unblock bluetooth
|
||||
if ! systemctl -q is-active bluetooth.service; then
|
||||
# This will use polkit for privillege elevation
|
||||
systemctl start bluetooth
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue