Add Node 20+ version check and engines field
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,2 +1,8 @@
|
||||
#!/usr/bin/env node
|
||||
import "../dist/index.js";
|
||||
const v = process.versions.node.split(".").map(Number);
|
||||
if (v[0] < 20) {
|
||||
console.error(`feynman requires Node.js 20 or later (you have ${process.versions.node})`);
|
||||
console.error("upgrade: https://nodejs.org or nvm install 20");
|
||||
process.exit(1);
|
||||
}
|
||||
import("../dist/index.js");
|
||||
|
||||
Reference in New Issue
Block a user