From 2c5c749f040f5aef0de0a49347583fda5434f49d Mon Sep 17 00:00:00 2001 From: Doug Date: Tue, 17 Dec 2024 10:55:24 +0000 Subject: [PATCH 1/2] Disable semantic commits from Renovate --- renovate.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index 5e5a3eafcd..ae25c1deb1 100644 --- a/renovate.json +++ b/renovate.json @@ -1,7 +1,8 @@ { "$schema": "https://docs.renovatebot.com/renovate-schema.json", "extends": [ - "config:recommended" + "config:recommended", + ":semanticCommitsDisabled" ], "labels" : [ "pr-misc" From 4c05cea1fea8edf38f31515afb597b12be0cc144 Mon Sep 17 00:00:00 2001 From: Doug Date: Tue, 17 Dec 2024 11:07:21 +0000 Subject: [PATCH 2/2] Add a Danger check for semantic commits. --- Dangerfile.swift | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Dangerfile.swift b/Dangerfile.swift index 9e1ae7fd20..137165c1ff 100644 --- a/Dangerfile.swift +++ b/Dangerfile.swift @@ -39,8 +39,10 @@ if hasPngs { } // Check for nice PR titles +let prTitle = danger.github.pullRequest.title let fixesRegex = try! Regex("(Fixes|Fix) #\\d+") -if danger.github.pullRequest.title.hasSuffix("…") || danger.github.pullRequest.title.starts(with: fixesRegex) { +let semanticRegex = try! Regex("\\w+\\(\\w+\\):") +if prTitle.hasSuffix("…") || prTitle.starts(with: fixesRegex) || prTitle.starts(with: semanticRegex) { fail("Please provide a complete title that can be used as a changelog entry.") }