neofetch: Fix windows resolution. Closes #1297

This commit is contained in:
Dylan Araps 2020-01-23 18:48:52 +02:00
parent 1588155964
commit 3dd3f7f8e7
No known key found for this signature in database
GPG key ID: 46D62DD9F1DE636E

View file

@ -2783,8 +2783,11 @@ get_resolution() {
;;
"Windows")
maparray -t sw < <(wmic path Win32_VideoController get CurrentHorizontalResolution)
maparray -t sh < <(wmic path Win32_VideoController get CurrentVerticalResolution)
IFS=$'\n' read -d "" -ra sw \
< <(wmic path Win32_VideoController get CurrentHorizontalResolution)
IFS=$'\n' read -d "" -ra sh \
< <(wmic path Win32_VideoController get CurrentVerticalResolution)
sw=("${sw[@]//CurrentHorizontalResolution}")
sh=("${sh[@]//CurrentHorizontalResolution}")