Unverified Commit e1d282ad authored by Nicolas Giard's avatar Nicolas Giard Committed by GitHub

feat: warn and exit on unsupported node version

parent fd002723
......@@ -6,6 +6,19 @@
const path = require('path')
const { nanoid } = require('nanoid')
const { DateTime } = require('luxon')
const { gte } = require('semver')
// ----------------------------------------
// Check Node.js version
// ----------------------------------------
if (gte(process.version, '18.0.0')) {
console.error('You\'re using an unsupported Node.js version. Please read the requirements.')
process.exit(1)
}
// ----------------------------------------
// Init WIKI instance
// ----------------------------------------
let WIKI = {
IS_DEBUG: process.env.NODE_ENV === 'development',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment