]> git.ipfire.org Git - thirdparty/git.git/blame - split-index.h
git-submodule.sh: shorten submodule SHA-1s using rev-parse
[thirdparty/git.git] / split-index.h
CommitLineData
5fc2fc8f
NTND
1#ifndef SPLIT_INDEX_H
2#define SPLIT_INDEX_H
3
2182abd9 4#include "cache.h"
5
5fc2fc8f
NTND
6struct index_state;
7struct strbuf;
96a1d8d3 8struct ewah_bitmap;
5fc2fc8f
NTND
9
10struct split_index {
2182abd9 11 struct object_id base_oid;
5fc2fc8f 12 struct index_state *base;
96a1d8d3
NTND
13 struct ewah_bitmap *delete_bitmap;
14 struct ewah_bitmap *replace_bitmap;
15 struct cache_entry **saved_cache;
5fc2fc8f 16 unsigned int saved_cache_nr;
76b07b37
NTND
17 unsigned int nr_deletions;
18 unsigned int nr_replacements;
5fc2fc8f
NTND
19 int refcount;
20};
21
22struct split_index *init_split_index(struct index_state *istate);
045113a5 23void save_or_free_index_entry(struct index_state *istate, struct cache_entry *ce);
078a58e8
NTND
24void replace_index_entry_in_base(struct index_state *istate,
25 struct cache_entry *old,
75b7b971 26 struct cache_entry *new_entry);
5fc2fc8f
NTND
27int read_link_extension(struct index_state *istate,
28 const void *data, unsigned long sz);
29int write_link_extension(struct strbuf *sb,
30 struct index_state *istate);
31void move_cache_to_base_index(struct index_state *istate);
32void merge_base_index(struct index_state *istate);
33void prepare_to_write_split_index(struct index_state *istate);
34void finish_writing_split_index(struct index_state *istate);
35void discard_split_index(struct index_state *istate);
cef4fc7e
CC
36void add_split_index(struct index_state *istate);
37void remove_split_index(struct index_state *istate);
5fc2fc8f
NTND
38
39#endif