diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-03-17 13:50:23 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-03-17 13:50:23 -0700 |
commit | 94c9b5af703eb70adba349cfbfaaa3029849744c (patch) | |
tree | cfb8557c71f0f2f8b586c63b9d51ae3a4745b48b /cache.h | |
parent | 32c43f595f93cdd4ed5305aef97a3f6aaa74ed72 (diff) | |
parent | b46013950aff31b6626af96ccbf2c48469e36c66 (diff) | |
download | git-94c9b5af703eb70adba349cfbfaaa3029849744c.tar.gz |
Merge branch 'cc/split-index-config'
The experimental "split index" feature has gained a few
configuration variables to make it easier to use.
* cc/split-index-config: (22 commits)
Documentation/git-update-index: explain splitIndex.*
Documentation/config: add splitIndex.sharedIndexExpire
read-cache: use freshen_shared_index() in read_index_from()
read-cache: refactor read_index_from()
t1700: test shared index file expiration
read-cache: unlink old sharedindex files
config: add git_config_get_expiry() from gc.c
read-cache: touch shared index files when used
sha1_file: make check_and_freshen_file() non static
Documentation/config: add splitIndex.maxPercentChange
t1700: add tests for splitIndex.maxPercentChange
read-cache: regenerate shared index if necessary
config: add git_config_get_max_percent_split_change()
Documentation/git-update-index: talk about core.splitIndex config var
Documentation/config: add information for core.splitIndex
t1700: add tests for core.splitIndex
update-index: warn in case of split-index incoherency
read-cache: add and then use tweak_split_index()
split-index: add {add,remove}_split_index() functions
config: add git_config_get_split_index()
...
Diffstat (limited to 'cache.h')
-rw-r--r-- | cache.h | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -1270,6 +1270,9 @@ extern int has_pack_index(const unsigned char *sha1); extern void assert_sha1_type(const unsigned char *sha1, enum object_type expect); +/* Helper to check and "touch" a file */ +extern int check_and_freshen_file(const char *fn, int freshen); + extern const signed char hexval_table[256]; static inline unsigned int hexval(unsigned char c) { @@ -1956,6 +1959,11 @@ extern int git_config_get_bool_or_int(const char *key, int *is_bool, int *dest); extern int git_config_get_maybe_bool(const char *key, int *dest); extern int git_config_get_pathname(const char *key, const char **dest); extern int git_config_get_untracked_cache(void); +extern int git_config_get_split_index(void); +extern int git_config_get_max_percent_split_change(void); + +/* This dies if the configured or default date is in the future */ +extern int git_config_get_expiry(const char *key, const char **output); /* * This is a hack for test programs like test-dump-untracked-cache to |