fix(azdo): strip credentials from origin URL in the not-ready message

This commit is contained in:
mika kuns
2026-10-01 12:38:02 +02:00
parent 27dca48c43
commit c834f17c78
2 changed files with 17 additions and 1 deletions
@@ -55,7 +55,7 @@ public sealed class PullRequestPublisher
return "Kein Azure-DevOps-PAT hinterlegt (Einstellungen → Externe Dienste) — nichts gepusht.";
var remote = await _git.GetRemoteUrlAsync(workingDir, "origin", ct);
return AzureDevOpsClient.ParseRemote(remote) is null
? $"origin ist kein https-Remote eines Azure DevOps Servers: {remote}"
? $"origin ist kein https-Remote eines Azure DevOps Servers: {System.Text.RegularExpressions.Regex.Replace(remote ?? "", "(?<=://)[^@/]+@", "")}"
: null;
}