2023-03-15 21:52:13 +00:00
|
|
|
# SPDX-FileCopyrightText: 2022 The CC: Tweaked Developers
|
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: CC0-1.0
|
|
|
|
|
2021-04-28 20:24:27 +00:00
|
|
|
# See https://pre-commit.com for more information
|
|
|
|
# See https://pre-commit.com/hooks.html for more hooks
|
|
|
|
repos:
|
|
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
2023-08-13 12:50:49 +00:00
|
|
|
rev: v4.4.0
|
2021-04-28 20:24:27 +00:00
|
|
|
hooks:
|
|
|
|
- id: trailing-whitespace
|
|
|
|
- id: end-of-file-fixer
|
|
|
|
- id: check-merge-conflict
|
|
|
|
|
|
|
|
# Quick syntax checkers
|
|
|
|
- id: check-xml
|
|
|
|
- id: check-yaml
|
|
|
|
- id: check-toml
|
|
|
|
- id: check-json
|
|
|
|
exclude: "tsconfig\\.json$"
|
|
|
|
|
|
|
|
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
|
2023-08-13 12:50:49 +00:00
|
|
|
rev: 2.7.2
|
2021-04-28 20:24:27 +00:00
|
|
|
hooks:
|
|
|
|
- id: editorconfig-checker
|
|
|
|
args: ['-disable-indentation']
|
|
|
|
exclude: "^(.*\\.(bat)|LICENSE)$"
|
|
|
|
|
2023-03-15 21:52:13 +00:00
|
|
|
- repo: https://github.com/fsfe/reuse-tool
|
2023-08-13 12:50:49 +00:00
|
|
|
rev: v2.1.0
|
2023-03-15 21:52:13 +00:00
|
|
|
hooks:
|
|
|
|
- id: reuse
|
|
|
|
|
2021-04-28 20:24:27 +00:00
|
|
|
- repo: local
|
|
|
|
hooks:
|
2022-10-22 16:47:39 +00:00
|
|
|
- id: license
|
|
|
|
name: Spotless
|
|
|
|
files: ".*\\.(java|kt|kts)$"
|
2021-04-28 20:24:27 +00:00
|
|
|
language: system
|
2022-10-22 16:47:39 +00:00
|
|
|
entry: ./gradlew spotlessApply
|
2021-04-28 20:24:27 +00:00
|
|
|
pass_filenames: false
|
|
|
|
require_serial: true
|
2022-10-22 16:47:39 +00:00
|
|
|
- id: checkstyle
|
|
|
|
name: Check Java codestyle
|
2021-05-15 20:27:48 +00:00
|
|
|
files: ".*\\.java$"
|
|
|
|
language: system
|
2023-10-03 08:06:17 +00:00
|
|
|
entry: ./gradlew checkstyle
|
2021-05-15 20:27:48 +00:00
|
|
|
pass_filenames: false
|
|
|
|
require_serial: true
|
2021-04-28 20:24:27 +00:00
|
|
|
- id: illuaminate
|
|
|
|
name: Check Lua code
|
|
|
|
files: ".*\\.(lua|java|md)"
|
2022-09-11 13:11:32 +00:00
|
|
|
language: system
|
2022-10-22 16:47:39 +00:00
|
|
|
entry: ./gradlew lintLua
|
2021-04-28 20:24:27 +00:00
|
|
|
pass_filenames: false
|
|
|
|
require_serial: true
|
|
|
|
|
|
|
|
exclude: |
|
|
|
|
(?x)^(
|
2022-11-09 23:58:56 +00:00
|
|
|
projects/[a-z]+/src/generated|
|
2022-11-04 22:31:56 +00:00
|
|
|
projects/core/src/test/resources/test-rom/data/json-parsing/|
|
2021-12-21 22:20:45 +00:00
|
|
|
.*\.dfpwm
|
2021-04-28 20:24:27 +00:00
|
|
|
)
|