@ethima/commitlint-config 1.1.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/LICENSE +1 -1
  2. package/package.json +7 -6
  3. package/src/index.js +8 -6
package/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2023 Joris Kraak
1
+ Copyright (c) 2023-2024 Joris Kraak
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of
4
4
  this software and associated documentation files (the "Software"), to deal in
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@ethima/commitlint-config",
3
- "version": "1.1.0",
3
+ "version": "2.1.0",
4
4
  "description": "A shareable Commitlint configuration for the Ethima organization",
5
5
  "main": "src/index.js",
6
+ "type": "module",
6
7
  "scripts": {
7
8
  "test": "ava"
8
9
  },
@@ -22,12 +23,12 @@
22
23
  },
23
24
  "homepage": "https://gitlab.com/ethima/commitlint-config",
24
25
  "dependencies": {
25
- "@commitlint/config-conventional": "18.4.3",
26
- "@commitlint/is-ignored": "18.4.3"
26
+ "@commitlint/config-conventional": "19.6.0",
27
+ "@commitlint/is-ignored": "19.6.0"
27
28
  },
28
29
  "devDependencies": {
29
- "@commitlint/lint": "18.4.3",
30
- "@commitlint/load": "18.4.3",
31
- "ava": "6.0.1"
30
+ "@commitlint/lint": "19.6.0",
31
+ "@commitlint/load": "19.5.0",
32
+ "ava": "6.2.0"
32
33
  }
33
34
  }
package/src/index.js CHANGED
@@ -1,7 +1,5 @@
1
- const baseConfiguration = require("@commitlint/config-conventional");
2
- const {
3
- wildcards: defaultIgnoreFunctions,
4
- } = require("@commitlint/is-ignored/lib/defaults");
1
+ import baseConfiguration from "@commitlint/config-conventional/lib/index.js";
2
+ import { wildcards as defaultIgnoreFunctions } from "@commitlint/is-ignored/lib/defaults.js";
5
3
 
6
4
  const footnoteMatcher = new RegExp("^\\[\\^.+?\\]:");
7
5
 
@@ -38,6 +36,8 @@ const buildMaxLineLengthWithFootnoteExemption = (section) => {
38
36
  // Only keep the default ignore functions allowing:
39
37
  //
40
38
  // - Merge/pull request merge commits into (pre)release branches.
39
+ // - Reapply commits (to allow reapplying previously reverted conventionally
40
+ // documented changes).
41
41
  // - Revert commits (to allow undoing/modifying previously conventionally
42
42
  // documented changes).
43
43
  //
@@ -45,7 +45,9 @@ const buildMaxLineLengthWithFootnoteExemption = (section) => {
45
45
  // straightforward to obtain them from the defaults
46
46
  const applicableDefaultIgnoreFunctions = defaultIgnoreFunctions.filter(
47
47
  (ignoreFunction) =>
48
- ignoreFunction("Revert ") || ignoreFunction("Merge 'x' into 'y' "),
48
+ ignoreFunction("Reapply ") ||
49
+ ignoreFunction("Revert ") ||
50
+ ignoreFunction("Merge 'x' into 'y' "),
49
51
  );
50
52
 
51
53
  // Ignore functions specific to this commitlint configuration
@@ -53,7 +55,7 @@ const configurationSpecificIgnoreFunctions = [
53
55
  semanticReleaseCommitMatcher.test.bind(semanticReleaseCommitMatcher),
54
56
  ];
55
57
 
56
- module.exports = {
58
+ export default {
57
59
  // Do not use the default ignore patterns as they allow patterns, e.g.
58
60
  // `fixup!` and `squash!` commits, that should be blocked in the workflows
59
61
  // primarily supported by this configuration