I am controlling the fan speed on my notebook using acpi and the command:
echo level n > /proc/acpi/ibm/fan- where
level nis a number between1and7.
It works, and after I changed the permissions of the fan file I was able to write to it from a terminal screen.
However, when I create a new launcher to do this from the desktop it doesn't work. The above line is in the 'Command' section and I have set permissions so that the icon is executed as a program but when I double-click on it nothing happens. There are no error messages displayed.
Is there something special about using the echo command in a launcher or am I doing this totally wrong?
1 Answer
I do this type of things a different way.
Create a script
~./local/bin/fan.shlike this:#!/bin/sh echo level 5 > /proc/acpi/ibm/fanMake it executable
chmod +x ~./local/bin/fan.shCreate a shortcut to this commad:
pkexec /home/$USER/.local/bin/fan.sh
It will ask for a password.
This is for 18.04. In previous versions use gksu instead of pkexec.