1
0
mirror of https://github.com/142vip/408CSFamily.git synced 2026-02-03 10:33:47 +08:00
Files
408CSFamily/scripts/lint
2023-09-06 19:24:23 +08:00

19 lines
341 B
JavaScript
Executable File

#!/usr/bin/env node
/**
*
* 格式化代码
* 例如:
* - ./scripts/lint
* - ./scripts/lint --fix
*/
const { execShell } = require("./.exec");
const scriptName=process.argv[2];
let fixed=''
if(scriptName!=null){
fixed='--fix'
}
;(async ()=>await execShell(`eslint ${fixed} --ext .js,.ts,.vue --ignore-path .gitignore .`))()