built-in rebase --skip/--abort: clean up stale .git/<name> files
[gitweb.git] / config.c
index 3555c63f284e6f80793e1ab341d4b9894f3a813e..4051e388230afb1fe96f1ffad35fcc36425d247b 100644 (file)
--- a/config.c
+++ b/config.c
@@ -2289,6 +2289,24 @@ int git_config_get_fsmonitor(void)
        return 0;
 }
 
+int git_config_get_index_threads(void)
+{
+       int is_bool, val = 0;
+
+       val = git_env_ulong("GIT_TEST_INDEX_THREADS", 0);
+       if (val)
+               return val;
+
+       if (!git_config_get_bool_or_int("index.threads", &is_bool, &val)) {
+               if (is_bool)
+                       return val ? 0 : 1;
+               else
+                       return val;
+       }
+
+       return 0; /* auto */
+}
+
 NORETURN
 void git_die_config_linenr(const char *key, const char *filename, int linenr)
 {