xref: /rk3399_ARM-atf/.commitlintrc.js (revision fa3a13824a8b025cbd69c0efa435892c81734448)
1/*
2 * Copyright (c) 2021, Arm Limited. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7/* eslint-env es6 */
8
9"use strict";
10
11const cz = require("./.cz.json");
12const { "trailer-exists": trailerExists } = require("@commitlint/rules").default;
13
14module.exports = {
15    extends: ["@commitlint/config-conventional"],
16    plugins: [
17        {
18            rules: {
19                "signed-off-by-exists": trailerExists,
20                "change-id-exists": trailerExists,
21            },
22        },
23    ],
24    rules: {
25        "body-max-line-length": [1, "always", cz.maxLineWidth], /* Warning */
26        "header-max-length": [1, "always", cz.maxHeaderWidth], /* Warning */
27
28        "change-id-exists": [1, "always", "Change-Id:"], /* Warning */
29        "signed-off-by-exists": [1, "always", "Signed-off-by:"], /* Warning */
30    },
31};
32