DUNGEONS-30: add access gateway with Telegram and Discord approvals
Co-authored-by: multica-agent <github@multica.ai>
This commit is contained in:
16
scripts/check.js
Normal file
16
scripts/check.js
Normal file
@@ -0,0 +1,16 @@
|
||||
import { readdirSync } from 'node:fs';
|
||||
import { join } from 'node:path';
|
||||
import { spawnSync } from 'node:child_process';
|
||||
|
||||
function check(directory) {
|
||||
for (const file of readdirSync(directory, { withFileTypes: true })) {
|
||||
const path = join(directory, file.name);
|
||||
if (file.isDirectory()) check(path);
|
||||
else if (file.name.endsWith('.js')) {
|
||||
const result = spawnSync(process.execPath, ['--check', path], { stdio: 'inherit' });
|
||||
if (result.status !== 0) process.exit(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
for (const directory of ['src', 'public', 'scripts', 'test']) check(directory);
|
||||
console.log('JavaScript syntax checks passed.');
|
||||
Reference in New Issue
Block a user