git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 2/9] send-email: visually distinguish sendmail aliases parser warnings

From
Eric Sunshine <sunshine@sunshineco.com>
Date
May 31, 2015, 22:29 UTC
Message-ID
<1433111371-19573-3-git-send-email-sunshine@sunshineco.com>
In-Reply-To
<1433111371-19573-1-git-send-email-sunshine@sunshineco.com>

Although emitted to stderr, warnings from the sendmail aliases parser are not visually distinguished as such, and thus can easily be overlooked in the normal noisy send-email output.

Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
---

This prepends lowercase "warning:" rather than uppercase since lowercase is used elsewhere in git-send-email.perl for diagnostic message prefixes.

 git-send-email.perl | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/git-send-email.perl b/git-send-email.perl
index 6bedf74..819f87e 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -522,12 +522,12 @@ my %parse_alias = (
 
 		# warn on lines that contain quotes
 		elsif (/"/) {
-			print STDERR "sendmail alias with quotes is not supported: $_\n";
+			print STDERR "warning: sendmail alias with quotes is not supported: $_\n";
 		}
 
 		# warn on lines that continue
 		elsif (/^\s|\\$/) {
-			print STDERR "sendmail continuation line is not supported: $_\n";
+			print STDERR "warning: sendmail continuation line is not supported: $_\n";
 		}
 
 		# recognize lines that look like an alias
@@ -538,7 +538,7 @@ my %parse_alias = (
 
 		# warn on lines that are not recognized
 		else {
-			print STDERR "sendmail line is not recognized: $_\n";
+			print STDERR "warning: sendmail line is not recognized: $_\n";
 		}}},
 
 	gnus => sub { my $fh = shift; while (<$fh>) {
-- 
2.4.2.538.g5f4350e
Previous: Allen HubbeNext: Eric Sunshine
Message 6 of 15 in “send-email: add sendmail aliases line continuation support”
  1. 0/9 send-email: add sendmail aliases line continuation supportEric Sunshine, May 31, 2015
  2. 1/9 send-email: further document missing sendmail aliases functionalityEric Sunshine, May 31, 2015
  3. Allen HubbeJun 1, 2015
  4. Eric SunshineJun 1, 2015
  5. Allen HubbeJun 1, 2015
  6. 2/9 send-email: visually distinguish sendmail aliases parser warningsEric Sunshine, May 31, 2015
  7. 3/9 send-email: drop noise comments which merely repeat what code saysEric Sunshine, May 31, 2015
  8. 4/9 send-email: fix style: cuddle 'elsif' and 'else' with closing braceEric Sunshine, May 31, 2015
  9. 5/9 send-email: refactor sendmail aliases parserEric Sunshine, May 31, 2015
  10. 6/9 send-email: simplify sendmail aliases comment and blank line recognizerEric Sunshine, May 31, 2015
  11. Eric SunshineJun 1, 2015
  12. 7/9 send-email: implement sendmail aliases line continuation supportEric Sunshine, May 31, 2015
  13. 8/9 t9001: refactor sendmail aliases test infrastructureEric Sunshine, May 31, 2015
  14. 9/9 t9001: add sendmail aliases line continuation testsEric Sunshine, May 31, 2015
  15. Allen HubbeJun 1, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.