Sha256: cbb0508b7853e39d36d1c57d91606a494a217550679cd59a466dd79962020b90
Contents?: true
Size: 424 Bytes
Versions: 32
Compression:
Stored size: 424 Bytes
Contents
require 'thread' Thread.abort_on_exception = true # Return the number of CPU cores (should work on Unixy platforms) def num_cpus return Java::Java.lang.Runtime.getRuntime.availableProcessors if defined? Java::Java return File.read('/proc/cpuinfo').scan(/^processor\s*:/).size if File.exist? '/proc/cpuinfo' return `sysctl -a | grep cpu`.split(/\s+/,2).last.to_i rescue return 2 end require_relative 'anschel/main'
Version data entries
32 entries across 32 versions & 1 rubygems