@itcase/config 1.6.39 → 1.6.41

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itcase/config",
3
- "version": "1.6.39",
3
+ "version": "1.6.41",
4
4
  "author": "ITCase",
5
5
  "description": "ITCase Config",
6
6
  "engines": {
@@ -10,6 +10,7 @@ import {
10
10
  } from './config.js'
11
11
 
12
12
  const releaseNotesGeneratorConfig = {
13
+ preset: PRESET,
13
14
  parserOpts: { noteKeywords: releaseNoteKeywords },
14
15
  presetConfig: {
15
16
  types: releaseNotesTypes,
@@ -17,11 +18,18 @@ const releaseNotesGeneratorConfig = {
17
18
  writerOpts: {
18
19
  commitsSort: COMMITS_SORT,
19
20
  commitFilter: (commit) => {
20
- const subject = commit.subject || commit.header || ''
21
- if (/^Merge\s/i.test(subject)) {
21
+ // Фильтруем merge коммиты более строго - проверяем subject независимо от типа
22
+ if (commit.subject) {
23
+ const mergePattern =
24
+ /^Merge (branch|pull request|commit|remote-tracking|.*into|.*of|made by)/i
25
+ if (mergePattern.test(commit.subject)) {
26
+ return false
27
+ }
28
+ }
29
+ // Также фильтруем коммиты без типа, которые выглядят как merge
30
+ if (!commit.type && commit.subject && /^Merge/i.test(commit.subject)) {
22
31
  return false
23
32
  }
24
-
25
33
  return true
26
34
  },
27
35
  },
@@ -69,17 +77,14 @@ function createSemanticReleaseConfig({
69
77
  }) {
70
78
  const plugins = [commonPlugins.commitAnalyzer]
71
79
 
72
- // Добавляем release-notes-generator только если не пропущен
73
80
  if (!skipReleaseNotesGenerator) {
74
81
  plugins.push(commonPlugins.releaseNotesGenerator)
75
82
  }
76
83
 
77
- // Дополнительные плагины (например, semantic-release-lerna) должны идти перед changelog и git
78
84
  plugins.push(...additionalPlugins)
79
85
 
80
86
  plugins.push(commonPlugins.changelog)
81
87
 
82
- // Добавляем npm плагин только если передан конфиг
83
88
  if (npmConfig !== null) {
84
89
  plugins.push(['@semantic-release/npm', npmConfig])
85
90
  }
@@ -15,11 +15,11 @@ const releaseRules = [
15
15
  const releaseNotesTypes = [
16
16
  { type: 'feat', section: 'Features' },
17
17
  { type: 'fix', section: 'Bug Fixes' },
18
- { type: 'refactor', release: 'Refactoring' },
18
+ { type: 'refactor', section: 'Refactoring' },
19
19
  { type: 'docs', section: 'Documentation' },
20
20
  { type: 'test', section: 'Tests' },
21
21
  { type: 'ci', section: 'Continuous Integrations' },
22
- { type: 'deps', release: 'Dependencies' },
22
+ { type: 'deps', section: 'Dependencies' },
23
23
  { type: 'other', section: 'Other' },
24
24
  ]
25
25