@@ -5,7 +5,7 @@ exclude: |
5
5
# Files and folders generated by bots, to avoid loops
6
6
^setup/|/static/description/index\.html$|
7
7
# We don't want to mess with tool-generated files
8
- .svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|
8
+ .svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|^eslint.config.cjs|^prettier.config.cjs|
9
9
# Maybe reactivate this when all README files include prettier ignore tags?
10
10
^README\.md$|
11
11
# Library files can have extraneous formatting (even minimized)
@@ -14,6 +14,10 @@ exclude: |
14
14
^docs/_templates/.*\.html$|
15
15
# Don't bother non-technical authors with formatting issues in docs
16
16
readme/.*\.(rst|md)$|
17
+ # Ignore build and dist directories in addons
18
+ /build/|/dist/|
19
+ # Ignore test files in addons
20
+ /tests/samples/.*|
17
21
# You don't usually want a bot to modify your legal texts
18
22
(LICENSE.*|COPYING.*)
19
23
default_language_version :
@@ -35,12 +39,19 @@ repos:
35
39
language : fail
36
40
files : ' [a-zA-Z0-9_]*/i18n/en\.po$'
37
41
- repo : https://github.com/oca/maintainer-tools
38
- rev : 969238e47c07d0c40573acff81d170f63245d738
42
+ rev : d5fab7ee87fceee858a3d01048c78a548974d935
39
43
hooks :
40
44
# update the NOT INSTALLABLE ADDONS section above
41
45
- id : oca-update-pre-commit-excluded-addons
42
46
- id : oca-fix-manifest-website
43
47
args : ["https://github.com/ForgeFlow/stock-rma"]
48
+ - repo : https://github.com/OCA/odoo-pre-commit-hooks
49
+ rev : v0.0.25
50
+ hooks :
51
+ - id : oca-checks-odoo-module
52
+ - id : oca-checks-po
53
+ args :
54
+ - --disable=po-pretty-format
44
55
- repo : https://github.com/myint/autoflake
45
56
rev : v1.6.1
46
57
hooks :
@@ -56,25 +67,35 @@ repos:
56
67
rev : 22.8.0
57
68
hooks :
58
69
- id : black
59
- - repo : https://github.com/pre-commit/mirrors-prettier
60
- rev : v2.7.1
70
+ - repo : local
61
71
hooks :
62
72
- id : prettier
63
73
name : prettier (with plugin-xml)
74
+ entry : prettier
75
+ args :
76
+ - --write
77
+ - --list-different
78
+ - --ignore-unknown
79
+ types : [text]
80
+ files : \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
81
+ language : node
64
82
additional_dependencies :
65
83
- " prettier@2.7.1"
66
84
- " @prettier/plugin-xml@2.2.0"
67
- args :
68
- - --plugin=@prettier/plugin-xml
69
- files : \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
70
- - repo : https://github.com/pre-commit/mirrors-eslint
71
- rev : v8.24.0
85
+ - repo : local
72
86
hooks :
73
87
- id : eslint
74
- verbose : true
88
+ name : eslint
89
+ entry : eslint
75
90
args :
76
91
- --color
77
92
- --fix
93
+ verbose : true
94
+ types : [javascript]
95
+ language : node
96
+ additional_dependencies :
97
+ - " eslint@8.24.0"
98
+ - " eslint-plugin-jsdoc@"
78
99
- repo : https://github.com/pre-commit/pre-commit-hooks
79
100
rev : v4.3.0
80
101
hooks :
@@ -115,7 +136,7 @@ repos:
115
136
hooks :
116
137
- id : setuptools-odoo-make-default
117
138
- repo : https://github.com/PyCQA/flake8
118
- rev : 3.9.2
139
+ rev : 5.0.0
119
140
hooks :
120
141
- id : flake8
121
142
name : flake8
0 commit comments