Skip to content

Instantly share code, notes, and snippets.

@leandroh
Created December 14, 2016 17:57
Show Gist options
  • Save leandroh/06784afa55b8c0bde10fcd647bb75583 to your computer and use it in GitHub Desktop.
Save leandroh/06784afa55b8c0bde10fcd647bb75583 to your computer and use it in GitHub Desktop.
Shows the number of processing units available (similar to nproc in unix)
require('os').cpus().length
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment