1+ exclude : |
2+ (?x)^(
3+ .*thirdparty/.*|
4+ .*-so_wrap\.(h|c)$
5+ )
6+
17repos :
28 - repo : https://github.com/pre-commit/mirrors-clang-format
39 rev : v17.0.6
713 types_or : [text]
814 exclude : |
915 (?x)^(
10- tests/python_build.*|
11- .*thirdparty.*|
12- .*platform/android/java/lib/src/com.*|
13- .*-so_wrap.*
16+ tests/python_build/.*|
17+ platform/android/java/lib/src/com/.*
1418 )
1519
1620 - repo : https://github.com/psf/black-pre-commit-mirror
@@ -19,33 +23,155 @@ repos:
1923 - id : black
2024 files : (\.py$|SConstruct|SCsub)
2125 types_or : [text]
22- exclude : .*thirdparty.*
2326 args :
2427 - --line-length=120
2528
29+ - repo : https://github.com/pre-commit/mirrors-mypy
30+ rev : v0.971
31+ hooks :
32+ - id : mypy
33+ files : \.py$
34+ types_or : [text]
35+ args : [--config-file=./misc/scripts/mypy.ini]
36+
37+ - repo : https://github.com/codespell-project/codespell
38+ rev : v2.2.6
39+ hooks :
40+ - id : codespell
41+ types_or : [text]
42+ exclude : |
43+ (?x)^(
44+ .*\.desktop$|
45+ .*\.gitignore$|
46+ .*\.po$|
47+ .*\.pot$|
48+ .*\.rc$|
49+ \.mailmap$|
50+ AUTHORS.md$|
51+ COPYRIGHT.txt$|
52+ DONORS.md$|
53+ core/input/gamecontrollerdb.txt$|
54+ core/string/locales.h$|
55+ editor/project_converter_3_to_4.cpp$|
56+ platform/android/java/lib/src/com/.*|
57+ platform/web/package-lock.json$
58+ )
59+ args :
60+ - --enable-colors
61+ - --write-changes
62+ - --check-hidden
63+ - --quiet-level
64+ - ' 3'
65+ - --ignore-words-list
66+ - aesthetic,aesthetics,breaked,cancelled,colour,curvelinear,doubleclick,expct,findn,gird,hel,inout,lod,mis,nd,numer,ot,requestor,te,thirdparty,vai
67+ - --builtin
68+ - clear,rare,en-GB_to_en-US
69+
70+ # ## Requires Docker; look into alternative implementation.
71+ # - repo: https://github.com/comkieffer/pre-commit-xmllint.git
72+ # rev: 1.0.0
73+ # hooks:
74+ # - id: xmllint
75+ # language: docker
76+ # types_or: [text]
77+ # files: ^(doc/classes|.*/doc_classes)/.*\.xml$
78+ # args: [--schema, doc/class.xsd]
79+
80+ - repo : https://github.com/pre-commit/mirrors-eslint
81+ rev : v8.46.0
82+ hooks :
83+ - id : eslint
84+ name : eslint-engine
85+ files : ^(platform/web/js/engine/|js/jsdoc2rst/).*\.js$
86+ args : [--fix, --no-eslintrc, --config, platform/web/.eslintrc.engine.js]
87+ additional_dependencies : &eslint-deps
88+ 89+ 90+ 91+ 92+ -
' @html-eslint/[email protected] ' 93+ -
' @html-eslint/[email protected] ' 94+ - id : eslint
95+ name : eslint-libs
96+ files : ^(platform/web/js/libs/|modules/).*\.js$
97+ args : [--fix, --no-eslintrc, --config, platform/web/.eslintrc.libs.js]
98+ additional_dependencies : *eslint-deps
99+ - id : eslint
100+ name : eslint-sw
101+ files : ^misc/dist/html/service-worker\.js$
102+ args : [--fix, --no-eslintrc, --config, platform/web/.eslintrc.sw.js]
103+ additional_dependencies : *eslint-deps
104+ - id : eslint
105+ name : eslint-html
106+ files : ^misc/dist/html/.*\.html$
107+ types : [html]
108+ args : [--fix, --no-eslintrc, --config, platform/web/.eslintrc.html.js]
109+ additional_dependencies : *eslint-deps
110+
26111 - repo : local
27112 hooks :
28113 - id : make-rst
29114 name : make-rst
115+ language : python
30116 entry : python3 doc/tools/make_rst.py doc/classes modules platform --dry-run --color
31117 pass_filenames : false
118+ files : ^(doc/classes|.*/doc_classes)/.*\.xml$
119+
120+ - id : doc-status
121+ name : doc-status
32122 language : python
33- files : ^(doc|modules|platform).*xml$
123+ entry : python3 doc/tools/doc_status.py
124+ files : ^(doc/classes|.*/doc_classes)/.*\.xml$
125+
126+ - id : jsdoc
127+ name : jsdoc
128+ language : node
129+ entry : jsdoc
130+ files : ^platform/web/js/engine/(engine|config|features)\.js$
131+ args : [--template, platform/web/js/jsdoc2rst/, --destination, '', -d, dry-run]
132+ additional_dependencies :
["[email protected] "] 34133
35134 - id : copyright-headers
36135 name : copyright-headers
37136 language : python
38- files : \.(c|h|cpp|hpp|cc|cxx|m|mm|inc|java)$
39137 entry : python3 misc/scripts/copyright_headers.py
138+ files : \.(c|h|cpp|hpp|cc|cxx|m|mm|inc|java)$
40139 exclude : |
41140 (?x)^(
42- .*thirdparty.*|
43- .*-so_wrap.*|
44141 core/math/bvh_.*\.inc$|
45- platform/android/java/lib/src/com.*|
46- platform/android/java/lib/src/org/godotengine/godot/gl/GLSurfaceView.*|
47- platform/android/java/lib/src/org/godotengine/godot/gl/EGLLogWrapper.*|
48- platform/android/java/lib/src/org/godotengine/godot/utils/ProcessPhoenix.*
142+ platform/android/java/lib/src/com/.*|
143+ platform/android/java/lib/src/org/godotengine/godot/gl/GLSurfaceView\.java$|
144+ platform/android/java/lib/src/org/godotengine/godot/gl/EGLLogWrapper\.java$|
145+ platform/android/java/lib/src/org/godotengine/godot/utils/ProcessPhoenix\.java$
146+ )
147+
148+ - id : header-guards
149+ name : header-guards
150+ language : python
151+ entry : python3 misc/scripts/header_guards.py
152+ files : \.(h|hpp)$
153+ exclude : |
154+ (?x)^(
155+ .*/thread\.h$|
156+ .*/platform_config\.h$|
157+ .*/platform_gl\.$h
158+ )
159+
160+ - id : file-format
161+ name : file-format
162+ language : python
163+ entry : python3 misc/scripts/file_format.py
164+ types_or : [text]
165+ exclude : |
166+ (?x)^(
167+ .*\.test\.txt$|
168+ .*\.svg$|
169+ .*\.patch$|
170+ .*\.out$|
171+ modules/gdscript/tests/scripts/parser/features/mixed_indentation_on_blank_lines\.gd$|
172+ modules/gdscript/tests/scripts/parser/warnings/empty_file_newline_comment\.notest\.gd$|
173+ modules/gdscript/tests/scripts/parser/warnings/empty_file_newline\.notest\.gd$|
174+ platform/android/java/lib/src/com/google/.*
49175 )
50176
51177 - id : dotnet-format
0 commit comments