Skip to content

Instantly share code, notes, and snippets.

View alshdavid's full-sized avatar

David Alsh alshdavid

View GitHub Profile
// Source of https://www.npmjs.com/package/physical-cpu-count
'use strict'
const os = require('os')
const childProcess = require('child_process')
function exec (command) {
const output = childProcess.execSync(command, {encoding: 'utf8'})
return output