Added linting, changed to esm loading

This commit is contained in:
2024-11-28 12:54:49 +02:00
parent 78e54af042
commit 44ff9878dd
5 changed files with 184 additions and 5 deletions

View File

@@ -1 +1,12 @@
import('../dist/index.js').then(module => module.default()).catch(console.error);
#!/usr/bin/env node
import { createRequire } from 'module';
import { fileURLToPath } from 'url';
import { dirname, join } from 'path';
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
const require = createRequire(import.meta.url);
const { default: run } = await import(join(__dirname, '../dist/index.js'));
run().catch(console.error);