differentiented power button behavior
This commit is contained in:
@@ -47,6 +47,21 @@
|
|||||||
with_items:
|
with_items:
|
||||||
- { name: sway-cyberboobs, path: ~/.config/sway/device-conf }
|
- { name: sway-cyberboobs, path: ~/.config/sway/device-conf }
|
||||||
become: no
|
become: no
|
||||||
|
- name: Set power button behavior
|
||||||
|
lineinfile:
|
||||||
|
line: "HandlePowerKey=hibernate"
|
||||||
|
path: "/etc/systemd/logind.conf"
|
||||||
|
regexp: '.*HandlePowerKey.*'
|
||||||
|
- name: set lidswitch behavior
|
||||||
|
lineinfile:
|
||||||
|
line: "HandleLidSwitch=suspend-then-hibernate"
|
||||||
|
path: "/etc/systemd/logind.conf"
|
||||||
|
regexp: '.*HandleLidSwitch.*'
|
||||||
|
- name: set hibernation delay
|
||||||
|
lineinfile:
|
||||||
|
line: "HibernateDelaySec=2h"
|
||||||
|
path: "/etc/systemd/sleep.conf"
|
||||||
|
regexp: '.*HibernateDelaySec.*'
|
||||||
handlers:
|
handlers:
|
||||||
- name: update initramfs
|
- name: update initramfs
|
||||||
command:
|
command:
|
||||||
|
|||||||
@@ -77,21 +77,6 @@
|
|||||||
user:
|
user:
|
||||||
name: vi
|
name: vi
|
||||||
shell: /usr/bin/fish
|
shell: /usr/bin/fish
|
||||||
- name: Set power button behavior
|
|
||||||
lineinfile:
|
|
||||||
line: "HandlePowerKey=hibernate"
|
|
||||||
path: "/etc/systemd/logind.conf"
|
|
||||||
regexp: '.*HandlePowerKey.*'
|
|
||||||
- name: set lidswitch behavior
|
|
||||||
lineinfile:
|
|
||||||
line: "HandleLidSwitch=suspend-then-hibernate"
|
|
||||||
path: "/etc/systemd/logind.conf"
|
|
||||||
regexp: '.*HandleLidSwitch.*'
|
|
||||||
- name: set hibernation delay
|
|
||||||
lineinfile:
|
|
||||||
line: "HibernateDelaySec=2h"
|
|
||||||
path: "/etc/systemd/sleep.conf"
|
|
||||||
regexp: '.*HibernateDelaySec.*'
|
|
||||||
- name: enable wireplumber
|
- name: enable wireplumber
|
||||||
systemd_service:
|
systemd_service:
|
||||||
name: wireplumber.service
|
name: wireplumber.service
|
||||||
|
|||||||
@@ -57,6 +57,11 @@
|
|||||||
with_items:
|
with_items:
|
||||||
- { name: sway-gridlock, path: ~/.config/sway/device-conf }
|
- { name: sway-gridlock, path: ~/.config/sway/device-conf }
|
||||||
become: no
|
become: no
|
||||||
|
- name: Set power button behavior
|
||||||
|
lineinfile:
|
||||||
|
line: "HandlePowerKey=poweroff"
|
||||||
|
path: "/etc/systemd/logind.conf"
|
||||||
|
regexp: '.*HandlePowerKey.*'
|
||||||
- name: install amd drivers and firmware
|
- name: install amd drivers and firmware
|
||||||
apt:
|
apt:
|
||||||
name:
|
name:
|
||||||
|
|||||||
Reference in New Issue
Block a user