defaults.js 935 B

1234567891011121314151617181920212223242526272829303132
  1. var ignoreRoot = require('ignore-by-default').directories();
  2. // default options for config.options
  3. const defaults = {
  4. restartable: 'rs',
  5. colours: true,
  6. execMap: {
  7. py: 'python',
  8. rb: 'ruby',
  9. ts: 'ts-node',
  10. // more can be added here such as ls: lsc - but please ensure it's cross
  11. // compatible with linux, mac and windows, or make the default.js
  12. // dynamically append the `.cmd` for node based utilities
  13. },
  14. ignoreRoot: ignoreRoot.map((_) => `**/${_}/**`),
  15. watch: ['*.*'],
  16. stdin: true,
  17. runOnChangeOnly: false,
  18. verbose: false,
  19. signal: 'SIGUSR2',
  20. // 'stdout' refers to the default behaviour of a required nodemon's child,
  21. // but also includes stderr. If this is false, data is still dispatched via
  22. // nodemon.on('stdout/stderr')
  23. stdout: true,
  24. watchOptions: {},
  25. };
  26. if ((process.env.NODE_OPTIONS || '').includes('--loader')) {
  27. delete defaults.execMap.ts;
  28. }
  29. module.exports = defaults;