<commit_before>#!/usr/bin/env node
const spawn = require('cross-spawn');
const script = process.argv[2];
const args = process.argv.slice(3);

switch (script) {
  case 'init':
  case 'test':
  case 'test-ssr':
  case 'build':
  case 'build-ssr':
  case 'lint':
  case 'format':
  case 'start':
  case 'start-ssr': {
    const scriptPath = require.resolve('../scripts/' + script);
    const scriptArgs = [scriptPath, ...args];

    const result = spawn.sync('node', scriptArgs, { stdio: 'inherit' });
    process.exit(result.status);
    break;
  }
  default: {
    console.log('Unknown script "' + script + '".');
    break;
  }
}<commit_msg>fix: Avoid cross-spawn to preserve abort errors (#156)<commit_after>#!/usr/bin/env node
const script = process.argv[2];

switch (script) {
  case 'init':
  case 'test':
  case 'test-ssr':
  case 'build':
  case 'build-ssr':
  case 'lint':
  case 'format':
  case 'start':
  case 'start-ssr': {
    const scriptPath = require.resolve('../scripts/' + script);
    require(scriptPath);
    break;
  }
  default: {
    console.log('Unknown script "' + script + '".');
    break;
  }
}
{'fraction_non_alphanumeric': 0.18376449598572703, 'fraction_numerical': 0.0053523639607493305, 'mean_word_length': 3.2661596958174903, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6142763', 'n_tokens_mistral': 391, 'n_tokens_neox': 384, 'n_words': 95}