-rw-r--r-- | cgit.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -223,4 +223,5 @@ int main(int argc, const char **argv) { struct cacheitem item; + const char *cgit_config_env = getenv("CGIT_CONFIG"); htmlfd = STDOUT_FILENO; @@ -230,5 +231,6 @@ int main(int argc, const char **argv) cgit_repolist.repos = NULL; - cgit_read_config(CGIT_CONFIG, cgit_global_config_cb); + cgit_read_config(cgit_config_env ? cgit_config_env : CGIT_CONFIG, + cgit_global_config_cb); cgit_repo = NULL; if (getenv("SCRIPT_NAME")) |