From c5f22dacb327c1fd931059935839e65f1ffc8459 Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Sat, 26 Mar 2016 08:36:00 +1100 Subject: [PATCH] added check for whether user wants refresh rate for linux --- README.md | 2 +- neofetch | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 672232c0..37379f34 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,7 @@ your distro's logo or any ascii art of your choice! - Wallpaper: `feh`, `nitrogen` or `gsettings` - Current Song: `mpc` or `cmus` -- Resolution: `xorg-xdpyinfo` or `xrandr` +- Resolution: `xorg-xdpyinfo` - Screenshot: `scrot` \[5\] diff --git a/neofetch b/neofetch index 8f2e06b2..cbb22b62 100755 --- a/neofetch +++ b/neofetch @@ -1273,7 +1273,7 @@ getsong () { getresolution () { case "$os" in "Linux" | *"BSD") - if type -p xrandr >/dev/null 2>&1; then + if type -p xrandr >/dev/null 2>&1 && [ "$refresh_rate" == "on" ]; then resolution=$(xrandr --nograb --current | awk 'match($0,/[0-0]{2,3}.[0-9]{2}\*/) {printf $1 " @ " substr($0,RSTART,RLENGTH) "Hz, "}') resolution=${resolution//\*}