Now it should work fine, just test to plug/unplug your computer. Now, you need to give execution rights to this file by typing sudo chmod +x /etc/pm/power.d/run_after_pwrmanagmt.sh Xinput set-int-prop 12 277 8 2 3 0 0 1 3 2Įcho 4000 > /sys/class/backlight/intel_backlight/brightness Then writes this code into this file : case '$' in Just creates a file sudo vi /etc/pm/power.d/run_after_pwrmanagmt.sh One solution is to add a script file in /etc/pm/power.d/
I tested a solution that works fine for me.