1
1
exclude : |
2
2
(?x)
3
3
# NOT INSTALLABLE ADDONS
4
+ ^sale_blanket_order_revision/|
4
5
# END NOT INSTALLABLE ADDONS
5
6
# Files and folders generated by bots, to avoid loops
6
7
^setup/|/static/description/index\.html$|
7
8
# We don't want to mess with tool-generated files
8
- .svg$|/tests/([^/]+/)?cassettes/|
9
+ .svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|
9
10
# Maybe reactivate this when all README files include prettier ignore tags?
10
11
^README\.md$|
11
12
# Library files can have extraneous formatting (even minimized)
12
13
/static/(src/)?lib/|
13
14
# Repos using Sphinx to generate docs don't need prettying
14
15
^docs/_templates/.*\.html$|
16
+ # Don't bother non-technical authors with formatting issues in docs
17
+ readme/.*\.(rst|md)$|
18
+ # Ignore build and dist directories in addons
19
+ /build/|/dist/|
20
+ # Ignore test files in addons
21
+ /tests/samples/.*|
15
22
# You don't usually want a bot to modify your legal texts
16
23
(LICENSE.*|COPYING.*)
17
24
default_language_version :
@@ -27,15 +34,33 @@ repos:
27
34
entry : found forbidden files; remove them
28
35
language : fail
29
36
files : " \\ .rej$"
37
+ - id : en-po-files
38
+ name : en.po files cannot exist
39
+ entry : found a en.po file
40
+ language : fail
41
+ files : ' [a-zA-Z0-9_]*/i18n/en\.po$'
30
42
- repo : https://github.com/oca/maintainer-tools
31
- rev : ab1d7f6
43
+ rev : 1b216173c7d11cf682492aefc149f02627068174
32
44
hooks :
33
45
# update the NOT INSTALLABLE ADDONS section above
34
46
- id : oca-update-pre-commit-excluded-addons
35
47
- id : oca-fix-manifest-website
36
48
args : ["https://github.com/OCA/sale-workflow"]
49
+ - id : oca-gen-addon-readme
50
+ args :
51
+ - --addons-dir=.
52
+ - --branch=14.0
53
+ - --org-name=OCA
54
+ - --repo-name=sale-workflow
55
+ - --if-source-changed
56
+ - --keep-source-digest
57
+ - repo : https://github.com/OCA/odoo-pre-commit-hooks
58
+ rev : v0.0.31
59
+ hooks :
60
+ - id : oca-checks-odoo-module
61
+ - id : oca-checks-po
37
62
- repo : https://github.com/myint/autoflake
38
- rev : v1.4
63
+ rev : v2.3.1
39
64
hooks :
40
65
- id : autoflake
41
66
args :
@@ -46,11 +71,11 @@ repos:
46
71
- --remove-duplicate-keys
47
72
- --remove-unused-variables
48
73
- repo : https://github.com/psf/black
49
- rev : 20.8b1
74
+ rev : 24.4.2
50
75
hooks :
51
76
- id : black
52
77
- repo : https://github.com/pre-commit/mirrors-prettier
53
- rev : v2.1.2
78
+ rev : v4.0.0-alpha.8
54
79
hooks :
55
80
- id : prettier
56
81
name : prettier (with plugin-xml)
@@ -61,15 +86,15 @@ repos:
61
86
- --plugin=@prettier/plugin-xml
62
87
files : \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
63
88
- repo : https://github.com/pre-commit/mirrors-eslint
64
- rev : v7 .8.1
89
+ rev : v9 .8.0
65
90
hooks :
66
91
- id : eslint
67
92
verbose : true
68
93
args :
69
94
- --color
70
95
- --fix
71
96
- repo : https://github.com/pre-commit/pre-commit-hooks
72
- rev : v3.2 .0
97
+ rev : v4.6 .0
73
98
hooks :
74
99
- id : trailing-whitespace
75
100
# exclude autogenerated files
@@ -91,20 +116,20 @@ repos:
91
116
- id : mixed-line-ending
92
117
args : ["--fix=lf"]
93
118
- repo : https://github.com/asottile/pyupgrade
94
- rev : v2.7.2
119
+ rev : v3.17.0
95
120
hooks :
96
121
- id : pyupgrade
97
122
args : ["--keep-percent-format"]
98
123
- repo : https://github.com/PyCQA/isort
99
- rev : 5.5.1
124
+ rev : 5.13.2
100
125
hooks :
101
126
- id : isort
102
127
name : isort except __init__.py
103
128
args :
104
129
- --settings=.
105
130
exclude : /__init__\.py$
106
131
- repo : https://github.com/acsone/setuptools-odoo
107
- rev : 2.6.0
132
+ rev : " 3.3 "
108
133
hooks :
109
134
- id : setuptools-odoo-make-default
110
135
- id : setuptools-odoo-get-requirements
@@ -113,25 +138,21 @@ repos:
113
138
- requirements.txt
114
139
- --header
115
140
- " # generated from manifests external_dependencies"
116
- - repo : https://gitlab .com/PyCQA/flake8
117
- rev : 3.8.3
141
+ - repo : https://github .com/PyCQA/flake8
142
+ rev : 7.1.0
118
143
hooks :
119
144
- id : flake8
120
145
name : flake8
121
146
additional_dependencies : ["flake8-bugbear==20.1.4"]
122
- - repo : https://github.com/PyCQA /pylint
123
- rev : pylint-2.5.3
147
+ - repo : https://github.com/OCA /pylint-odoo
148
+ rev : v9.1.2
124
149
hooks :
125
- - id : pylint
150
+ - id : pylint_odoo
126
151
name : pylint with optional checks
127
152
args :
128
153
- --rcfile=.pylintrc
129
154
- --exit-zero
130
155
verbose : true
131
- additional_dependencies : &pylint_deps
132
- - pylint-odoo==3.5.0
133
- - id : pylint
134
- name : pylint with mandatory checks
156
+ - id : pylint_odoo
135
157
args :
136
158
- --rcfile=.pylintrc-mandatory
137
- additional_dependencies : *pylint_deps
0 commit comments