Files
discordeno/scripts/checkCpuModel.js
T
2023-03-08 14:47:19 -08:00

8 lines
294 B
JavaScript

import os from 'node:os'
const hostCpu = os.cpus()[0].model
const targetCpu = await fetch('https://raw.githubusercontent.com/discordeno/discordeno/benchies/cpu').then((res) => res.text())
console.log(`host cpu: ${hostCpu} target cpu: ${targetCpu}`)
if (hostCpu !== targetCpu) process.exit(1)