From 5675c40295d6edeeb742786f129cb609cc1508e1 Mon Sep 17 00:00:00 2001 From: AKP Date: Mon, 7 Mar 2022 18:32:26 +0000 Subject: [PATCH] Add "fix" `df` command exiting with bogus status code This commit addresses the issue documented in flatpak/xdg-desktop-portal#512 by using `df -x fuse.portal` as opposed to just `df`. Fix sourced from: https://www.mail-archive.com/desktop-packages%40lists.launchpad.net/msg651194.html This appears to have come about because of an issue introduced when upgrading to Linux Mint 20.3. Signed-off-by: AKP --- internal/providers/disk.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/providers/disk.go b/internal/providers/disk.go index 827f8c5..d90f2aa 100644 --- a/internal/providers/disk.go +++ b/internal/providers/disk.go @@ -25,7 +25,7 @@ func NewDisk(mountPath string, okThreshold, warningThreshold float32) i3bar.Bloc } func (g *Disk) getAvailable() (float32, error) { - cmdout, err := runCommand("df") + cmdout, err := runCommand("df", "-x", "fuse.portal") if err != nil { return 0, err }