summaryrefslogtreecommitdiff
path: root/.eslintrc.json
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-02-25 20:21:05 -0500
committerGitHub <noreply@github.com>2021-02-25 20:21:05 -0500
commit782b945905c948b9a0495aa85524ad1a92c7bd97 (patch)
tree2dfe5e1b38a2f448f77f62135a974ca75002090f /.eslintrc.json
parentb2f225a0d6a63d65d0543539d688d33c51a4fb8e (diff)
Header lint (#1444)
* Add eslint-plugin-header * Add rule for header format * Add missing header * Fix header issues
Diffstat (limited to '.eslintrc.json')
-rw-r--r--.eslintrc.json26
1 files changed, 24 insertions, 2 deletions
diff --git a/.eslintrc.json b/.eslintrc.json
index 297f7500..4bed4a0d 100644
--- a/.eslintrc.json
+++ b/.eslintrc.json
@@ -14,7 +14,10 @@
"es2017": true,
"webextensions": true
},
- "plugins": ["no-unsanitized"],
+ "plugins": [
+ "no-unsanitized",
+ "header"
+ ],
"ignorePatterns": [
"/ext/lib/"
],
@@ -82,7 +85,26 @@
"template-tag-spacing": ["error", "never"],
"no-unsanitized/method": "error",
- "no-unsanitized/property": "error"
+ "no-unsanitized/property": "error",
+
+ "header/header": ["error", "block", [
+ "",
+ {"pattern": " \\* Copyright \\(C\\) (\\d+-)?2021 Yomichan Authors"},
+ " *",
+ " * This program is free software: you can redistribute it and/or modify",
+ " * it under the terms of the GNU General Public License as published by",
+ " * the Free Software Foundation, either version 3 of the License, or",
+ " * (at your option) any later version.",
+ " *",
+ " * This program is distributed in the hope that it will be useful,",
+ " * but WITHOUT ANY WARRANTY; without even the implied warranty of",
+ " * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the",
+ " * GNU General Public License for more details.",
+ " *",
+ " * You should have received a copy of the GNU General Public License",
+ " * along with this program. If not, see <https://www.gnu.org/licenses/>.",
+ " "
+ ]]
},
"overrides": [
{