generate_arxiv_digest.js 469 B

1234567891011121314151617181920
  1. #!/usr/bin/env node
  2. const { spawnSync } = require('child_process');
  3. const path = require('path');
  4. const repoRoot = __dirname;
  5. const script = path.join(repoRoot, 'arxiv-digest', 'scripts', 'run_daily.py');
  6. const args = [script, ...process.argv.slice(2)];
  7. const result = spawnSync('python3', args, {
  8. cwd: repoRoot,
  9. stdio: 'inherit',
  10. env: process.env,
  11. });
  12. if (result.error) {
  13. console.error(result.error);
  14. process.exit(1);
  15. }
  16. process.exit(result.status ?? 0);