Browse Source

commit.h: reduce unnecessary includes

Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
main
Elijah Newren 1 year ago committed by Junio C Hamano
parent
commit
d4a4f9291d
  1. 1
      add-interactive.c
  2. 2
      archive.c
  3. 1
      bloom.c
  4. 1
      builtin/diff-tree.c
  5. 1
      builtin/diff.c
  6. 1
      builtin/gc.c
  7. 1
      builtin/log.c
  8. 1
      builtin/merge-tree.c
  9. 1
      combine-diff.c
  10. 1
      commit-graph.c
  11. 1
      commit.c
  12. 11
      commit.h
  13. 1
      dir.c
  14. 1
      fetch-pack.c
  15. 1
      fsck.c
  16. 1
      gpg-interface.c
  17. 1
      grep.c
  18. 1
      http-push.c
  19. 1
      log-tree.c
  20. 1
      merge-ort-wrappers.c
  21. 1
      merge.c
  22. 1
      notes-cache.c
  23. 1
      notes-utils.c
  24. 1
      object-name.c
  25. 1
      pack-bitmap-write.c
  26. 1
      parse-options-cb.c
  27. 1
      parse-options.c
  28. 1
      read-cache.c
  29. 1
      ref-filter.c
  30. 1
      reflog.c
  31. 1
      refs/debug.c
  32. 1
      refspec.c
  33. 1
      revision.h
  34. 1
      send-pack.c
  35. 1
      wt-status.c

1
add-interactive.c

@ -12,6 +12,7 @@ @@ -12,6 +12,7 @@
#include "dir.h"
#include "run-command.h"
#include "prompt.h"
#include "tree.h"

static void init_color(struct repository *r, struct add_i_state *s,
const char *section_and_slot, char *dst,

2
archive.c

@ -6,10 +6,12 @@ @@ -6,10 +6,12 @@
#include "environment.h"
#include "gettext.h"
#include "hex.h"
#include "pretty.h"
#include "setup.h"
#include "refs.h"
#include "object-store.h"
#include "commit.h"
#include "tree.h"
#include "tree-walk.h"
#include "attr.h"
#include "archive.h"

1
bloom.c

@ -6,6 +6,7 @@ @@ -6,6 +6,7 @@
#include "hashmap.h"
#include "commit-graph.h"
#include "commit.h"
#include "commit-slab.h"

define_commit_slab(bloom_filter_slab, struct bloom_filter);


1
builtin/diff-tree.c

@ -9,6 +9,7 @@ @@ -9,6 +9,7 @@
#include "builtin.h"
#include "submodule.h"
#include "repository.h"
#include "tree.h"

static struct rev_info log_tree_opt;


1
builtin/diff.c

@ -22,6 +22,7 @@ @@ -22,6 +22,7 @@
#include "setup.h"
#include "submodule.h"
#include "oid-array.h"
#include "tree.h"

#define DIFF_NO_INDEX_EXPLICIT 1
#define DIFF_NO_INDEX_IMPLICIT 2

1
builtin/gc.c

@ -12,6 +12,7 @@ @@ -12,6 +12,7 @@

#include "builtin.h"
#include "abspath.h"
#include "date.h"
#include "environment.h"
#include "hex.h"
#include "repository.h"

1
builtin/log.c

@ -44,6 +44,7 @@ @@ -44,6 +44,7 @@
#include "commit-reach.h"
#include "range-diff.h"
#include "tmp-objdir.h"
#include "tree.h"
#include "write-or-die.h"

#define MAIL_DEFAULT_WRAP 72

1
builtin/merge-tree.c

@ -16,6 +16,7 @@ @@ -16,6 +16,7 @@
#include "exec-cmd.h"
#include "merge-blobs.h"
#include "quote.h"
#include "tree.h"

static int line_termination = '\n';


1
combine-diff.c

@ -13,6 +13,7 @@ @@ -13,6 +13,7 @@
#include "xdiff/xmacros.h"
#include "log-tree.h"
#include "refs.h"
#include "tree.h"
#include "userdiff.h"
#include "oid-array.h"
#include "revision.h"

1
commit-graph.c

@ -23,6 +23,7 @@ @@ -23,6 +23,7 @@
#include "shallow.h"
#include "json-writer.h"
#include "trace2.h"
#include "tree.h"
#include "chunk-format.h"
#include "wrapper.h"


1
commit.c

@ -26,6 +26,7 @@ @@ -26,6 +26,7 @@
#include "run-command.h"
#include "setup.h"
#include "shallow.h"
#include "tree.h"
#include "hook.h"

static struct commit_extra_header *read_commit_extra_header_lines(const char *buf, size_t len, const char **);

11
commit.h

@ -2,13 +2,10 @@ @@ -2,13 +2,10 @@
#define COMMIT_H

#include "object.h"
#include "tree.h"
#include "strbuf.h"
#include "decorate.h"
#include "gpg-interface.h"
#include "string-list.h"
#include "pretty.h"
#include "commit-slab.h"

struct signature_check;
struct strbuf;
struct tree;

#define COMMIT_NOT_FROM_GRAPH 0xFFFFFFFF
#define GENERATION_NUMBER_INFINITY ((1ULL << 63) - 1)

1
dir.c

@ -27,6 +27,7 @@ @@ -27,6 +27,7 @@
#include "submodule-config.h"
#include "symlinks.h"
#include "trace2.h"
#include "tree.h"
#include "wrapper.h"

/*

1
fetch-pack.c

@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
#include "alloc.h"
#include "repository.h"
#include "config.h"
#include "date.h"
#include "environment.h"
#include "gettext.h"
#include "hex.h"

1
fsck.c

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
#include "git-compat-util.h"
#include "alloc.h"
#include "date.h"
#include "hex.h"
#include "object-store.h"
#include "repository.h"

1
gpg-interface.c

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
#include "git-compat-util.h"
#include "commit.h"
#include "config.h"
#include "date.h"
#include "gettext.h"
#include "run-command.h"
#include "strbuf.h"

1
grep.c

@ -4,6 +4,7 @@ @@ -4,6 +4,7 @@
#include "grep.h"
#include "hex.h"
#include "object-store.h"
#include "pretty.h"
#include "userdiff.h"
#include "xdiff-interface.h"
#include "diff.h"

1
http-push.c

@ -15,6 +15,7 @@ @@ -15,6 +15,7 @@
#include "setup.h"
#include "sigchain.h"
#include "strvec.h"
#include "tree.h"
#include "packfile.h"
#include "object-store.h"
#include "commit-reach.h"

1
log-tree.c

@ -24,6 +24,7 @@ @@ -24,6 +24,7 @@
#include "help.h"
#include "range-diff.h"
#include "strmap.h"
#include "tree.h"
#include "write-or-die.h"

static struct decoration name_decoration = { "object names" };

1
merge-ort-wrappers.c

@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
#include "hash.h"
#include "merge-ort.h"
#include "merge-ort-wrappers.h"
#include "tree.h"

#include "commit.h"


1
merge.c

@ -7,6 +7,7 @@ @@ -7,6 +7,7 @@
#include "commit.h"
#include "run-command.h"
#include "resolve-undo.h"
#include "tree.h"
#include "tree-walk.h"
#include "unpack-trees.h"
#include "dir.h"

1
notes-cache.c

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
#include "git-compat-util.h"
#include "notes-cache.h"
#include "object-store.h"
#include "pretty.h"
#include "repository.h"
#include "commit.h"
#include "refs.h"

1
notes-utils.c

@ -6,6 +6,7 @@ @@ -6,6 +6,7 @@
#include "refs.h"
#include "notes-utils.h"
#include "repository.h"
#include "strbuf.h"

void create_notes_commit(struct repository *r,
struct notes_tree *t,

1
object-name.c

@ -15,6 +15,7 @@ @@ -15,6 +15,7 @@
#include "dir.h"
#include "oid-array.h"
#include "packfile.h"
#include "pretty.h"
#include "object-store.h"
#include "repository.h"
#include "setup.h"

1
pack-bitmap-write.c

@ -18,6 +18,7 @@ @@ -18,6 +18,7 @@
#include "commit-reach.h"
#include "prio-queue.h"
#include "trace2.h"
#include "tree.h"

struct bitmapped_commit {
struct commit *commit;

1
parse-options-cb.c

@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
#include "branch.h"
#include "commit.h"
#include "color.h"
#include "date.h"
#include "environment.h"
#include "gettext.h"
#include "object-name.h"

1
parse-options.c

@ -5,6 +5,7 @@ @@ -5,6 +5,7 @@
#include "commit.h"
#include "color.h"
#include "gettext.h"
#include "strbuf.h"
#include "utf8.h"

static int disallow_abbreviated_options;

1
read-cache.c

@ -6,6 +6,7 @@ @@ -6,6 +6,7 @@
#include "cache.h"
#include "alloc.h"
#include "config.h"
#include "date.h"
#include "diff.h"
#include "diffcore.h"
#include "hex.h"

1
ref-filter.c

@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
#include "alloc.h"
#include "environment.h"
#include "gettext.h"
#include "gpg-interface.h"
#include "hex.h"
#include "parse-options.h"
#include "refs.h"

1
reflog.c

@ -4,6 +4,7 @@ @@ -4,6 +4,7 @@
#include "reflog.h"
#include "refs.h"
#include "revision.h"
#include "tree.h"
#include "worktree.h"

/* Remember to update object flag allocation in object.h */

1
refs/debug.c

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
#include "git-compat-util.h"
#include "hex.h"
#include "refs-internal.h"
#include "string-list.h"
#include "trace.h"

static struct trace_key trace_refs = TRACE_KEY_INIT(REFS);

1
refspec.c

@ -6,6 +6,7 @@ @@ -6,6 +6,7 @@
#include "strvec.h"
#include "refs.h"
#include "refspec.h"
#include "strbuf.h"

static struct refspec_item s_tag_refspec = {
.force = 0,

1
revision.h

@ -8,6 +8,7 @@ @@ -8,6 +8,7 @@
#include "pretty.h"
#include "diff.h"
#include "commit-slab-decl.h"
#include "decorate.h"
#include "ident.h"
#include "list-objects-filter-options.h"


1
send-pack.c

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
#include "git-compat-util.h"
#include "config.h"
#include "commit.h"
#include "date.h"
#include "gettext.h"
#include "hex.h"
#include "refs.h"

1
wt-status.c

@ -22,6 +22,7 @@ @@ -22,6 +22,7 @@
#include "strbuf.h"
#include "trace.h"
#include "trace2.h"
#include "tree.h"
#include "utf8.h"
#include "worktree.h"
#include "lockfile.h"

Loading…
Cancel
Save