mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-10-04 17:09:21 +00:00
Supress xprop errors if xprop isn't installed
This commit is contained in:
4
neofetch
4
neofetch
@@ -820,8 +820,8 @@ getde () {
|
||||
|
||||
getwm () {
|
||||
if [ -n "$DISPLAY" ] && [ "$os" != "Mac OS X" ]; then
|
||||
id="$(xprop -root -notype | awk '$1=="_NET_SUPPORTING_WM_CHECK:"{print $5}')"
|
||||
wm="$(xprop -id "$id" -notype -f _NET_WM_NAME 8t)"
|
||||
id="$(xprop -root -notype | awk '$1=="_NET_SUPPORTING_WM_CHECK:"{print $5}' 2>/dev/null)"
|
||||
wm="$(xprop -id "$id" -notype -f _NET_WM_NAME 8t 2>/dev/null)"
|
||||
wm=${wm/*_NET_WM_NAME = }
|
||||
wm=${wm/\"}
|
||||
wm=${wm/\"*}
|
||||
|
Reference in New Issue
Block a user