Skip to contentSkip to conversation

config: tell the user that we expect an ASCII character

PATCH In review Kristoffer Haugsbakk 2 participants 2 messages Mar 27, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 config: tell the user that we expect an ASCII character

Commit 50b54fd72a (config: be strict on core.commentChar, 2014-05-17) notes that “multi-byte character encoding could also be misinterpreted”, and indeed a multi-byte codepoint (non-ASCII) is not accepted as a valid core.commentChar.

---
 config.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
config.c +1 -1
index 00090a32fc..ae68c0f736 100644
@@ -1683,7 +1683,7 @@ static int git_default_core_config(const char *var, const char *value, void *cb)
 			comment_line_char = value[0];
 			auto_comment_line_char = 0;
 		} else
-			return error(_("core.commentChar should only be one character"));
+			return error(_("core.commentChar should only be one ASCII character"));
 		return 0;
 	}
 
Signature · 1 line
2.40.0
#1 lore raw
Quoted 4 lines · Kristoffer Haugsbakk

Commit 50b54fd72a (config: be strict on core.commentChar, 2014-05-17) notes that “multi-byte character encoding could also be misinterpreted”, and indeed a multi-byte codepoint (non-ASCII) is not accepted as a valid core.commentChar.

Makes sense. Will queue. Thanks.