<commit_before>#!/usr/bin/env python

import os
import subprocess
import sys

from lib.util import *


SOURCE_ROOT = os.path.dirname(os.path.dirname(__file__))


def main():
  input_file = sys.argv[1]
  output_dir = os.path.dirname(sys.argv[2])

  coffee = os.path.join(SOURCE_ROOT, 'node_modules', 'coffee-script', 'bin',
                        'coffee')
  subprocess.check_call(['node', coffee, '-c', '-o', output_dir, input_file])


if __name__ == '__main__':
  sys.exit(main())<commit_msg>[Win] Fix running node from python.<commit_after>#!/usr/bin/env python

import os
import subprocess
import sys

from lib.util import *


SOURCE_ROOT = os.path.dirname(os.path.dirname(__file__))


def main():
  input_file = sys.argv[1]
  output_dir = os.path.dirname(sys.argv[2])

  coffee = os.path.join(SOURCE_ROOT, 'node_modules', 'coffee-script', 'bin',
                        'coffee')
  if sys.platform in ['win32', 'cygwin']:
    subprocess.check_call(['node', coffee, '-c', '-o', output_dir, input_file],
                          executable='C:/Program Files/nodejs/node.exe')
  else:
    subprocess.check_call(['node', coffee, '-c', '-o', output_dir, input_file])

if __name__ == '__main__':
  sys.exit(main())
{'fraction_non_alphanumeric': 0.16474464579901152, 'fraction_numerical': 0.004942339373970346, 'mean_word_length': 3.533582089552239, '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': '779843', 'n_tokens_mistral': 436, 'n_tokens_neox': 418, 'n_words': 88}