.overcommit.yml 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. # Don't complain when changing branches with different overcommit configurations.
  2. verify_signatures: false
  3. CommitMsg:
  4. ALL:
  5. enabled: false
  6. EmptyMessage:
  7. enabled: true
  8. PreCommit:
  9. ALL:
  10. enabled: false
  11. RuboCop:
  12. enabled: true
  13. on_warn: fail
  14. command: ['bundle', 'exec', 'rubocop']
  15. CoffeeLint:
  16. required_executable: 'coffeelint'
  17. install_command: 'npm install -g @coffeelint/cli'
  18. # .dev/coffeelint/rules/* not supported in YAML, specify all rules separately.
  19. flags:
  20. [
  21. '--reporter=csv',
  22. '--rules',
  23. './.dev/coffeelint/rules/detect_translatable_string.coffee',
  24. ]
  25. enabled: true
  26. on_warn: fail
  27. exclude: 'public/assets/chat/**/*'
  28. Stylelint:
  29. enabled: true
  30. required_executable: 'yarn'
  31. command: ['yarn', '--silent', 'lint:css']
  32. TranslationCatalogCheck:
  33. required_executable: 'rails'
  34. enabled: true
  35. env:
  36. ZAMMAD_SAFE_MODE: '1'
  37. command: ['rails', 'generate', 'zammad:translation_catalog', '--check']
  38. SettingsTypesCheck:
  39. required_executable: 'rails'
  40. enabled: true
  41. env:
  42. ZAMMAD_SAFE_MODE: '1'
  43. command: ['rails', 'generate', 'zammad:setting_types', '--check']
  44. include:
  45. - 'db/seeds/settings.rb'
  46. GraphQLAPICheck:
  47. required_executable: '.gitlab/check_graphql_api_consistency.sh'
  48. enabled: true
  49. command: ['.gitlab/check_graphql_api_consistency.sh']
  50. include:
  51. - 'app/graphql/**/*'
  52. - 'app/frontend/**/*.graphql'
  53. TypeCheck:
  54. required_executable: 'yarn'
  55. enabled: true
  56. command: ['yarn', 'lint:ts']
  57. exclude:
  58. - 'node_modules'
  59. - 'public'
  60. - 'vendor'
  61. include:
  62. - 'app/frontend/**/*'
  63. - '**/*.cy.ts'
  64. - '**/cypress/**/*.ts'
  65. - './vite.config.*'
  66. - './vitest.setup.ts'
  67. EsLint:
  68. required_executable: 'yarn'
  69. enabled: true
  70. command: ['yarn', 'lint:js']
  71. exclude:
  72. - 'app/assets/**/*'
  73. - 'public/assets/chat/**/*'
  74. - 'public/assets/form/**/*'
  75. include:
  76. - '**/*.js'
  77. - '**/*.ts'
  78. - '**/*.vue'
  79. PostCheckout:
  80. ALL:
  81. enabled: false
  82. PostCommit:
  83. ALL:
  84. enabled: false
  85. PostMerge:
  86. ALL:
  87. enabled: false
  88. PostRewrite:
  89. ALL:
  90. enabled: false
  91. PrePush:
  92. ALL:
  93. enabled: false
  94. CustomScript:
  95. enabled: true
  96. description: "Verify GraphQL introspection file is not empty."
  97. required_executable: 'bash'
  98. command: [ 'bash', '-c', 'test -s app/graphql/graphql_introspection.json' ]
  99. on_warn: fail
  100. PreRebase:
  101. ALL:
  102. enabled: false
  103. PrepareCommitMsg:
  104. ALL:
  105. enabled: false