From cd3bf364cfe8bab573599bee457db6c95694a69e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Bersier?= Date: Thu, 25 Jul 2019 07:52:01 +0200 Subject: [PATCH] Update how it shows on linux --- commands/utility/stats.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commands/utility/stats.js b/commands/utility/stats.js index 23799b5..dc34d9c 100644 --- a/commands/utility/stats.js +++ b/commands/utility/stats.js @@ -43,7 +43,7 @@ class StatsCommand extends Command { const { stdout } = await exec('sysctl -n machdep.cpu.brand_string'); cpu = stdout; } else if (process.platform == 'linux') { - const { stdout } = await exec('grep -m 1 \'model name\' /proc/cpuinfo'); + const { stdout } = await exec('lscpu | grep "Model name:" | sed -r \'s/Model name:\\s{1,}//g\''); cpu = stdout; } else if (process.platform == 'win32') { const { stdout } = await exec('wmic CPU get NAME');