Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const task: TaskFn = (absPath, _app, state) => {
if (!state.eslint) {
return
}
const eslint = new JsonFile(absPath, '.eslintrc.json')
eslint.set('extends', ['plugin:adonis/typescriptApp'])
eslint.commit()
const eslintIgnore = new LinesFile(absPath, '.eslintignore')
eslintIgnore.add('build')
eslintIgnore.commit()
logger.create('.eslintrc.json, .eslintignore')
}
const task: TaskFn = (absPath) => {
const gitignore = new LinesFile(absPath, '.gitignore')
gitignore.add('node_modules')
gitignore.add('build')
gitignore.add('coverage')
gitignore.add('.vscode')
gitignore.add('.DS_STORE')
gitignore.add('.env')
gitignore.commit()
logger.create('.gitignore')
}