Only view the CPU temperature from command `sensors`
You can process the output of sensors
command with grep
and/or cut
to format it the way you want.
To get only the line reporting the CPU temperature you can use this (including the high and critical limits):
sensors | grep -A 0 'CPU T'
The following will give you only the temperature (with the °C suffix) :
sensors | grep -A 0 'CPU T' | cut -c18-25
This will give the output as you indicated at the end of your question:
sensors | grep -A 0 'CPU T' | cut -c1-25
The string below should work for you. grep -A[4] gives the next 4 lines The watch -d refreshes the changes and -d highlights the difference from the last refresh.
watch -d 'sensors | grep 'CPU Temperature''
Install the small apci
package with the following command:
sudo apt-get install acpi
You will need to press Y for confirmation for the first time.
Now to find the CPU temperature with this command:
acpi -t