feat(review): a WARN opens the lock only when every counting MAJOR is answered

This commit is contained in:
Kjell Tore Guttormsen 2026-11-02 15:45:37 +01:00
commit ce7dbc27a9
Signed by: ktg
SSH key fingerprint: SHA256:JakMjO6FTBBzN0Bhfj9saOoEjaFxlSdYuZQQpM/lF9Q
8 changed files with 1044 additions and 64 deletions

View file

@ -44,7 +44,7 @@ const DEFAULT_MESSAGE = 'docs(voyage): record approval';
const TRAILER_RE = /^Co-Authored-By: [^\s<>{}](?:[^<>{}\n]*[^\s<>{}])? <[^\s<>@]+@[^\s<>]+>$/;
/** @returns {string|null} why `trailer` is refused, or null when it is valid */
function trailerProblem(trailer) {
export function trailerProblem(trailer) {
if (typeof trailer !== 'string' || trailer === '') {
return '--trailer "Co-Authored-By: <name> <<email>>" is required — nothing committed';
}