1 | const path = require('path');
|
2 | const { shell } = require('./utils');
|
3 | const rootDir = process.cwd();
|
4 |
|
5 | module.exports = async function anuxLint(args) {
|
6 | let dir = args[0] || './src';
|
7 | dir = path.resolve(rootDir, dir);
|
8 | await shell(`npx eslint --ext .ts --ext .tsx --ext .js --ext .jsx --fix --color=true ${dir}`);
|
9 | } |
\ | No newline at end of file |