From 15859c73e62aa6fe0fc6e704e9fdbebd39db1e13 Mon Sep 17 00:00:00 2001 From: aminnairi <18418459+aminnairi@users.noreply.github.com> Date: Tue, 11 Apr 2023 14:58:33 +0200 Subject: [PATCH] fixed the fetching of the RAM --- i3/i3status/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/i3/i3status/index.js b/i3/i3status/index.js index a93cdfe..1a63d99 100644 --- a/i3/i3status/index.js +++ b/i3/i3status/index.js @@ -166,8 +166,8 @@ const getVolume = async () => { const getMemory = async () => { return Promise.all([ - execute("cat /proc/meminfo | grep MemTotal | cut -d ' ' -f 9"), - execute("cat /proc/meminfo | grep MemFree | cut -d ' ' -f 11") + execute("/usr/bin/cat /proc/meminfo | grep MemTotal | cut -d ' ' -f 8"), + execute("/usr/bin/cat /proc/meminfo | grep MemFree | cut -d ' ' -f 10") ]).then(([rawTotalMemory, rawFreeMemory]) => { const totalMemory = Math.round((Number(rawTotalMemory.trim()) || 0) / 100000) / 10; const freeMemory = Math.round((Number(rawFreeMemory.trim()) || 0) / 100000) / 10;