diff --git a/package.json b/package.json index 6c20fc17..79b84da7 100644 --- a/package.json +++ b/package.json @@ -44,7 +44,7 @@ }, "devDependencies": { "@release-it/conventional-changelog": "^8.0.0", - "@types/conventional-commits-parser": "^3.0.4", + "@types/conventional-commits-parser": "^5.0.0", "@types/eslint": "^8.44.3", "@types/pkgjs__parseargs": "^0.10.1", "@typescript-eslint/eslint-plugin": "^7.0.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index fad21630..8ef03ebc 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,8 +17,8 @@ devDependencies: specifier: ^8.0.0 version: 8.0.1(release-it@17.0.0) '@types/conventional-commits-parser': - specifier: ^3.0.4 - version: 3.0.4 + specifier: ^5.0.0 + version: 5.0.0 '@types/eslint': specifier: ^8.44.3 version: 8.44.3 @@ -1413,8 +1413,8 @@ packages: resolution: {integrity: sha512-C5Mc6rdnsaJDjO3UpGW/CQTHtCKaYlScZTly4JIu97Jxo/odCiH0ITnDXSJPTOrEKk/ycSZ0AOgTmkDtkOsvIA==} dev: true - /@types/conventional-commits-parser@3.0.4: - resolution: {integrity: sha512-nO3LTqFyExqXWAAfcsGh63gPLmYZSAqlLZfhqJ57qkgtyd0BA8S8M/mqtWCD/PvegjuaGk1z4UG5Hy7bZq79zA==} + /@types/conventional-commits-parser@5.0.0: + resolution: {integrity: sha512-loB369iXNmAZglwWATL+WRe+CRMmmBPtpolYzIebFaX4YA3x+BEfLqhUAV9WanycKI3TG1IMr5bMJDajDKLlUQ==} dependencies: '@types/node': 18.11.18 dev: true diff --git a/src/getCommitMeaning.ts b/src/getCommitMeaning.ts index 52243d9f..38be23f3 100644 --- a/src/getCommitMeaning.ts +++ b/src/getCommitMeaning.ts @@ -9,11 +9,9 @@ const releaseCommitTester = export function getCommitMeaning(message: string) { // Some types are always meaningful or ignored, regardless of potentially release-like messages - // options from https://github.com/conventional-changelog/conventional-changelog/issues/648#issuecomment-704867077 - // https://github.com/JoshuaKGoldberg/should-semantic-release/issues/174 const { notes, type } = conventionalCommitsParser.sync(message, { breakingHeaderPattern: /^(\w*)(?:\((.*)\))?!: (.*)$/, - } as object); + }); if (notes.some((note) => note.title.match(/^BREAKING[ -]CHANGE$/))) { return "meaningful"; }