node --print 'os.cpus().length' --require os

Category: Node.js & npm/yarn

node --print 'os.cpus().length' --require os

Quick one-liner to check a system value using a built-in Node module

A quick way to evaluate a Node expression that uses a built-in module — prints the number of CPU cores here.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.