From 91143de1a5619435492a8cfd1c953dd80d0d10d3 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Sat, 17 Dec 2016 00:06:12 +1100 Subject: [PATCH] Disk: Use -P for all OS --- neofetch | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/neofetch b/neofetch index 1c89a8ab..94e71769 100755 --- a/neofetch +++ b/neofetch @@ -1539,15 +1539,8 @@ get_term_font() { get_disk() { type -p df >/dev/null 2>&1 || { err "Disk requires 'df' to function. Install 'df' to get disk info."; return; } - # Split the info - case "$os" in - "Haiku") return ;; - "Mac OS X") df_flags=(-P -h /) ;; - *) df_flags=(-h /) ;; - esac - # Get the info for / - disks=($(df "${df_flags[@]}")) || { err "Disk: 'df' exited with error code 1"; return; } + disks=($(df -P -h /)) || { err "Disk: 'df' exited with error code 1"; return; } disk_used="${disks[9]}" disk_total="${disks[8]}"