summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ec31d0d)
raw | patch | inline | side by side (parent: ec31d0d)
author | Jonas Fonseca <fonseca@diku.dk> | |
Mon, 20 Aug 2007 21:03:21 +0000 (23:03 +0200) | ||
committer | Jonas Fonseca <fonseca@diku.dk> | |
Tue, 21 Aug 2007 10:23:06 +0000 (12:23 +0200) |
TODO | patch | blob | history | |
configure.ac | patch | blob | history | |
tig.c | patch | blob | history |
index 9ff2b3273a51dea041712ef3545bc5271ce398b0..8e18e60bb08f5d1d66cac948c465045f7dc7034c 100644 (file)
--- a/TODO
+++ b/TODO
- Use autoconf to check for the AsciiDoc and XmlTo document tools.
- - The autoconf check could also be used to determine whether it is a
- newer git so that git-config will be used instead of git-repo-config.
-
- Use non-blocking I/O + select() for incremental loading of view
input. (debian bug #427093)
diff --git a/configure.ac b/configure.ac
index 0e06af5136804f192caa7df371fbdfc9c5c3d956..0c060ce900fab5cf89d6102abfd4ed2c8adb7ca3 100644 (file)
--- a/configure.ac
+++ b/configure.ac
fi
AC_PROG_CC
+AC_CHECK_PROGS(GIT_CONFIG, [git-config git-repo-config])
+AC_DEFINE_UNQUOTED(GIT_CONFIG,"$GIT_CONFIG",[git config program])
AC_CONFIG_FILES([config.make])
AC_OUTPUT
index 1ad92644ebe5efc94d50d72e3f5ce65bb465d022..21dd6c2f8e1d7db9862dd03a2a0d15614917edfe 100644 (file)
--- a/tig.c
+++ b/tig.c
#define SCALE_SPLIT_VIEW(height) ((height) * 2 / 3)
+#ifndef GIT_CONFIG
+#define "git config"
+#endif
+
#define TIG_LS_REMOTE \
"git ls-remote $(git rev-parse --git-dir) 2>/dev/null"
@@ -4304,7 +4308,7 @@ read_repo_config_option(char *name, size_t namelen, char *value, size_t valuelen
static int
load_repo_config(void)
{
- return read_properties(popen("git repo-config --list", "r"),
+ return read_properties(popen(GIT_CONFIG " --list", "r"),
"=", read_repo_config_option);
}