summaryrefslogtreecommitdiffstats
path: root/README
diff options
context:
space:
mode:
authorMatt Hunter <m@lfurio.us>2026-06-01 03:30:15 -0400
committerMatt Hunter <m@lfurio.us>2026-06-01 03:30:15 -0400
commit07d6f75fa751361f6fd9d5f35155fb2885402a87 (patch)
tree0cfc7808226e7345489619a657e5ffbc8b404364 /README
parent45f88d69871e1a9385f11c4162ea6cd84f04c6c0 (diff)
downloadgit-sonar-07d6f75fa751361f6fd9d5f35155fb2885402a87.tar.gz
git-sonar-07d6f75fa751361f6fd9d5f35155fb2885402a87.zip
Fix %{alert} not rendering when upstream is missing
Though the command used to initialize $upstream_name will return a failed exit code when where is not a upstream branch available, that command will still echo its argument to stdout, which ends up in our variable. This ends up not breaking most usage of the value, as it doesn't contain a real ref - but the [ -z "$upstream_name" ] check in element_alert would essentially never evaluate true. Handle failed cases by initializing $upstream_name with an empty string. Fixes: cee3f0443ff9 ("Bulk rewrite of git-sonar script") Signed-off-by: Matt Hunter <m@lfurio.us>
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions