config: don't include config.h by default

Stop including config.h by default in cache.h.  Instead only include
config.h in those files which require use of the config system.

Signed-off-by: Brandon Williams <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Brandon Williams 2017-06-14 11:07:36 -07:00 committed by Junio C Hamano
parent f1c985da05
commit b2141fc1d2
146 changed files with 145 additions and 1 deletions

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
int advice_push_update_rejected = 1;
int advice_push_non_ff_current = 1;

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
struct config_alias_data {
const char *alias;

View File

@ -8,6 +8,7 @@
*/
#include "cache.h"
#include "config.h"
#include "blob.h"
#include "delta.h"
#include "diff.h"

View File

@ -2,6 +2,7 @@
* Copyright (c) 2005, 2006 Rene Scharfe
*/
#include "cache.h"
#include "config.h"
#include "tar.h"
#include "archive.h"
#include "streaming.h"

View File

@ -2,6 +2,7 @@
* Copyright (c) 2006 Rene Scharfe
*/
#include "cache.h"
#include "config.h"
#include "archive.h"
#include "streaming.h"
#include "utf8.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "commit.h"
#include "tree-walk.h"

1
attr.c
View File

@ -9,6 +9,7 @@
#define NO_THE_INDEX_COMPATIBILITY_MACROS
#include "cache.h"
#include "config.h"
#include "exec_cmd.h"
#include "attr.h"
#include "dir.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "diff.h"
#include "revision.h"

View File

@ -1,5 +1,6 @@
#include "git-compat-util.h"
#include "cache.h"
#include "config.h"
#include "branch.h"
#include "refs.h"
#include "remote.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) 2006 Linus Torvalds
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "lockfile.h"
#include "dir.h"

View File

@ -4,6 +4,7 @@
* Based on git-am.sh by Junio C Hamano.
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "exec_cmd.h"
#include "parse-options.h"

View File

@ -6,6 +6,7 @@
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "builtin.h"
#include "blob.h"

View File

@ -6,6 +6,7 @@
*/
#include "cache.h"
#include "config.h"
#include "color.h"
#include "refs.h"
#include "commit.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "parse-options.h"
#include "userdiff.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "attr.h"
#include "quote.h"
#include "parse-options.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "quote.h"
#include "pathspec.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "mailmap.h"
#include "parse-options.h"
#include "string-list.h"

View File

@ -5,6 +5,7 @@
*
*/
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "quote.h"
#include "cache-tree.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "parse-options.h"
#include "refs.h"

View File

@ -8,6 +8,7 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "parse-options.h"
#include "string-list.h"

View File

@ -9,6 +9,7 @@
*/
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "parse-options.h"
#include "fetch-pack.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "strbuf.h"
#include "parse-options.h"
#include "string-list.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "tree.h"
#include "builtin.h"

View File

@ -6,6 +6,7 @@
*/
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "cache-tree.h"
#include "color.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "color.h"
#include "parse-options.h"
#include "urlmatch.h"

View File

@ -5,6 +5,7 @@
*/
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "builtin.h"
#include "parse-options.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "commit.h"
#include "tag.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "diff.h"
#include "commit.h"
#include "revision.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "diff.h"
#include "commit.h"
#include "revision.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "diff.h"
#include "commit.h"
#include "log-tree.h"

View File

@ -4,6 +4,7 @@
* Copyright (c) 2006 Junio C Hamano
*/
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "color.h"
#include "commit.h"

View File

@ -12,6 +12,7 @@
* Copyright (C) 2016 Johannes Schindelin
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "run-command.h"
#include "exec_cmd.h"

View File

@ -5,6 +5,7 @@
*/
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "commit.h"
#include "object.h"

View File

@ -2,6 +2,7 @@
* "git fetch"
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "commit.h"
#include "builtin.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "commit.h"
#include "diff.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "object.h"
#include "parse-options.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "tree.h"
#include "blob.h"

View File

@ -11,6 +11,7 @@
*/
#include "builtin.h"
#include "config.h"
#include "tempfile.h"
#include "lockfile.h"
#include "parse-options.h"

View File

@ -4,6 +4,7 @@
* Copyright (c) 2006 Junio C Hamano
*/
#include "cache.h"
#include "config.h"
#include "blob.h"
#include "tree.h"
#include "commit.h"

View File

@ -5,6 +5,7 @@
* Copyright (C) Junio C Hamano, 2005
*/
#include "builtin.h"
#include "config.h"
#include "blob.h"
#include "quote.h"
#include "parse-options.h"

View File

@ -2,6 +2,7 @@
* Builtin help command
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "exec_cmd.h"
#include "parse-options.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "delta.h"
#include "pack.h"
#include "csum-file.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "builtin.h"
#include "exec_cmd.h"

View File

@ -5,6 +5,7 @@
* 2006 Junio Hamano
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "color.h"
#include "commit.h"

View File

@ -6,6 +6,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "quote.h"
#include "dir.h"
#include "builtin.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "blob.h"
#include "tree.h"
#include "commit.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "refs.h"
#include "diff.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "xdiff/xdiff.h"
#include "xdiff-interface.h"
#include "parse-options.h"

View File

@ -7,6 +7,7 @@
*/
#include "cache.h"
#include "config.h"
#include "parse-options.h"
#include "builtin.h"
#include "lockfile.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) 2006 Johannes Schindelin
*/
#include "builtin.h"
#include "config.h"
#include "pathspec.h"
#include "lockfile.h"
#include "dir.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "tag.h"
#include "refs.h"

View File

@ -8,6 +8,7 @@
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "notes.h"
#include "blob.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "attr.h"
#include "object.h"
#include "blob.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
static void flush_current_id(int patchlen, struct object_id *id, struct object_id *result)
{

View File

@ -6,6 +6,7 @@
* Fetch one or more remote refs and merge it/them into the current HEAD.
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "parse-options.h"
#include "exec_cmd.h"

View File

@ -2,6 +2,7 @@
* "git push"
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "run-command.h"
#include "builtin.h"

View File

@ -5,6 +5,7 @@
*/
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "object.h"
#include "tree.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "parse-options.h"
#include "sequencer.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "pack.h"
#include "refs.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "commit.h"
#include "refs.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "parse-options.h"
#include "transport.h"
#include "remote.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "parse-options.h"
#include "run-command.h"

View File

@ -9,6 +9,7 @@
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "refs.h"
#include "parse-options.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "parse-options.h"
#include "string-list.h"

View File

@ -8,6 +8,7 @@
* Copyright (c) 2005, 2006 Linus Torvalds and Junio C Hamano
*/
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "tag.h"
#include "object.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "diff.h"
#include "revision.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "refs.h"
#include "quote.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "parse-options.h"
#include "diff.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds 2006
*/
#include "builtin.h"
#include "config.h"
#include "lockfile.h"
#include "dir.h"
#include "cache-tree.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "commit.h"
#include "refs.h"
#include "pkt-line.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "diff.h"
#include "string-list.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "commit.h"
#include "refs.h"
#include "builtin.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "parse-options.h"
#include "strbuf.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "parse-options.h"
#include "quote.h"
#include "pathspec.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
#include "cache.h"
#include "refs.h"
#include "parse-options.h"

View File

@ -7,6 +7,7 @@
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "refs.h"
#include "tag.h"

View File

@ -1,4 +1,5 @@
#include "builtin.h"
#include "config.h"
static char *create_temp_file(unsigned char *sha1)
{

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "object.h"
#include "delta.h"
#include "pack.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "quote.h"
#include "cache-tree.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "builtin.h"
#include "parse-options.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "parse-options.h"

View File

@ -4,6 +4,7 @@
* Copyright (C) Eric Biederman, 2005
*/
#include "builtin.h"
#include "config.h"
static const char var_usage[] = "git var (-l | <variable>)";

View File

@ -6,6 +6,7 @@
* Based on git-verify-tag
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "commit.h"
#include "run-command.h"

View File

@ -1,5 +1,6 @@
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "run-command.h"
#include "parse-options.h"

View File

@ -6,6 +6,7 @@
* Based on git-verify-tag.sh
*/
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "tag.h"
#include "run-command.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "builtin.h"
#include "dir.h"
#include "parse-options.h"

View File

@ -5,6 +5,7 @@
*/
#include "builtin.h"
#include "cache.h"
#include "config.h"
#include "tree.h"
#include "cache-tree.h"
#include "parse-options.h"

View File

@ -11,7 +11,6 @@
#include "string-list.h"
#include "pack-revindex.h"
#include "hash.h"
#include "config.h"
#ifndef platform_SHA_CTX
/*

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "color.h"
static int git_use_color_default = GIT_COLOR_AUTO;

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "column.h"
#include "string-list.h"
#include "parse-options.h"

View File

@ -6,6 +6,7 @@
#define PRECOMPOSE_UNICODE_C
#include "cache.h"
#include "config.h"
#include "utf8.h"
#include "precompose_utf8.h"

View File

@ -6,6 +6,7 @@
*
*/
#include "cache.h"
#include "config.h"
#include "lockfile.h"
#include "exec_cmd.h"
#include "strbuf.h"

View File

@ -1,5 +1,6 @@
#include "git-compat-util.h"
#include "cache.h"
#include "config.h"
#include "pkt-line.h"
#include "quote.h"
#include "refs.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "attr.h"
#include "run-command.h"
#include "quote.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "tempfile.h"
#include "credential.h"
#include "unix-socket.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "credential.h"
#include "string-list.h"
#include "run-command.h"

View File

@ -1,4 +1,5 @@
#include "cache.h"
#include "config.h"
#include "pkt-line.h"
#include "run-command.h"
#include "strbuf.h"

1
diff.c
View File

@ -2,6 +2,7 @@
* Copyright (C) 2005 Junio C Hamano
*/
#include "cache.h"
#include "config.h"
#include "tempfile.h"
#include "quote.h"
#include "diff.h"

1
dir.c
View File

@ -8,6 +8,7 @@
* Junio Hamano, 2005-2006
*/
#include "cache.h"
#include "config.h"
#include "dir.h"
#include "attr.h"
#include "refs.h"

View File

@ -8,6 +8,7 @@
* are.
*/
#include "cache.h"
#include "config.h"
#include "refs.h"
#include "fmt-merge-msg.h"
#include "commit.h"

Some files were not shown because too many files have changed in this diff Show More