repo-settings: introduce commitgraph.changedPathsVersion
A subsequent commit will introduce another version of the changed-path filter in the commit graph file. In order to control which version to write (and read), a config variable is needed. Therefore, introduce this config variable. For forwards compatibility, teach Git to not read commit graphs when the config variable is set to an unsupported version. Because we teach Git this, commitgraph.readChangedPaths is now redundant, so deprecate it and define its behavior in terms of the config variable we introduce. This commit does not change the behavior of writing (Git writes changed path filters when explicitly instructed regardless of any config variable), but a subsequent commit will restrict Git such that it will only write when commitgraph.changedPathsVersion is a recognized value. Signed-off-by: Jonathan Tan <jonathantanmy@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
c99c59e68f
commit
e96587de93
@ -29,7 +29,7 @@ struct repo_settings {
|
||||
|
||||
int core_commit_graph;
|
||||
int commit_graph_generation_version;
|
||||
int commit_graph_read_changed_paths;
|
||||
int commit_graph_changed_paths_version;
|
||||
int gc_write_commit_graph;
|
||||
int fetch_write_commit_graph;
|
||||
int command_requires_full_index;
|
||||
|
Reference in New Issue
Block a user