summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 55d1eb0)
raw | patch | inline | side by side (parent: 55d1eb0)
author | Junio C Hamano <junkio@cox.net> | |
Mon, 28 Nov 2005 00:09:40 +0000 (16:09 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Mon, 28 Nov 2005 00:09:40 +0000 (16:09 -0800) |
This is to hold what the project-local rule as to the
charset/encoding for the commit log message is. Lack of it
defaults to utf-8.
Signed-off-by: Junio C Hamano <junkio@cox.net>
charset/encoding for the commit log message is. Lack of it
defaults to utf-8.
Signed-off-by: Junio C Hamano <junkio@cox.net>
cache.h | patch | blob | history | |
config.c | patch | blob | history | |
environment.c | patch | blob | history |
index 61bf884f83c121a0f0de13eaa38ca36677a8d34f..634b5aa69cddc412af74da94991bee96101e2701 100644 (file)
--- a/cache.h
+++ b/cache.h
extern char git_default_email[MAX_GITNAME];
extern char git_default_name[MAX_GITNAME];
+#define MAX_ENCODING_LENGTH 64
+extern char git_commit_encoding[MAX_ENCODING_LENGTH];
+
/* Sane ctype - no locale, and works with signed chars */
#undef isspace
#undef isdigit
diff --git a/config.c b/config.c
index 0c43d7615b68cb41b60a140bdcf26559b24cc3e0..152fa282f0853d42e5be767770e6dfa04887a0d3 100644 (file)
--- a/config.c
+++ b/config.c
return 0;
}
+ if (!strcmp(var, "i18n.commitencoding")) {
+ strncpy(git_commit_encoding, value, sizeof(git_commit_encoding));
+ return 0;
+ }
+
/* Add other config variables here.. */
return 0;
}
diff --git a/environment.c b/environment.c
index 3f194732e539918413277dbfda6e11924eda43bb..0886ad38f94ddb897629d832160333921ac89481 100644 (file)
--- a/environment.c
+++ b/environment.c
int trust_executable_bit = 1;
int only_use_symrefs = 0;
int repository_format_version = 0;
+char git_commit_encoding[MAX_ENCODING_LENGTH] = "utf-8";
static char *git_dir, *git_object_dir, *git_index_file, *git_refs_dir,
*git_graft_file;