taskDescriptor.js 478 B

1234567891011121314151617181920
  1. const task = {
  2. match: /vue-cli-service lint/,
  3. description: 'org.vue.eslint.tasks.lint.description',
  4. link: 'https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-eslint#injected-commands',
  5. prompts: [
  6. {
  7. name: 'noFix',
  8. type: 'confirm',
  9. default: false,
  10. description: 'org.vue.eslint.tasks.lint.noFix'
  11. }
  12. ],
  13. onBeforeRun: ({ answers, args }) => {
  14. if (answers.noFix) args.push('--no-fix')
  15. }
  16. }
  17. module.exports = {
  18. task
  19. }