scripts: only use grep when detecting the amount of cpus available