From f754c3fe215bc4ee4f41500c2d68397a5e6b188e Mon Sep 17 00:00:00 2001 From: dar-irl Date: Mon, 16 May 2016 15:45:42 -0400 Subject: [PATCH] Support screen resolution on Windows 10 Edited the WMIC command used so that the screen resolution can be obtained on Windows 10. --- neofetch | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/neofetch b/neofetch index 1c7048f3..2d5963ac 100755 --- a/neofetch +++ b/neofetch @@ -1543,12 +1543,12 @@ getresolution () { ;; "Windows") - width=$(wmic desktopmonitor get screenwidth /value 2>/dev/null) - width=${width/ScreenWidth'='/} + width=$(wmic path Win32_VideoController get CurrentHorizontalResolution /value 2>/dev/null) + width=${width/CurrentHorizontalResolution'='/} width=${width//[[:space:]]} - height=$(wmic desktopmonitor get screenheight /value 2>/dev/null) - height=${height/ScreenHeight'='/} + height=$(wmic path Win32_VideoController get CurrentVerticalResolution /value 2>/dev/null) + height=${height/CurrentVerticalResolution'='/} height=${height//[[:space:]]} [ ! -z "$width" ] && \