Skip to content

Instantly share code, notes, and snippets.

@blindFS
Created October 23, 2013 02:33
Show Gist options
  • Save blindFS/7111720 to your computer and use it in GitHub Desktop.
Save blindFS/7111720 to your computer and use it in GitHub Desktop.
#!/bin/bash
bumble_status=$(optirun --status|awk -F " " '{print $NF}')
if [ "$bumble_status" = "off." ]; then
echo "Gpu : off"
exit 0
fi
bumble_temp=$( optirun --no-xorg nvidia-smi -q -d TEMPERATURE | grep Gpu)
echo "$(echo $bumble_temp | sed 's/\(\S\+\) C/ +\1.0°C/g')"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment