diff options
author | Derrick Stolee <dstolee@microsoft.com> | 2020-10-15 17:22:03 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-10-16 08:36:42 -0700 |
commit | 61f7a383d3b9a7306f1fd44a8dfa070deacc0752 (patch) | |
tree | a3a32480d13bc5a104b0067039b45f46806d61a1 /Documentation | |
parent | maintenance: create maintenance.strategy config (diff) | |
download | tgif-61f7a383d3b9a7306f1fd44a8dfa070deacc0752.tar.xz |
maintenance: use 'incremental' strategy by default
The 'git maintenance (register|start)' subcommands add the current
repository to the global Git config so maintenance will operate on that
repository. It does not specify what maintenance should occur or how
often.
To make it simple for users to start background maintenance with a
recommended schedlue, update the 'maintenance.strategy' config option in
both the 'register' and 'start' subcommands. This allows users to
customize beyond the defaults using individual
'maintenance.<task>.schedule' options, but also the user can opt-out of
this strategy using 'maintenance.strategy=none'.
Helped-by: Martin Ă…gren <martin.agren@gmail.com>
Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/git-maintenance.txt | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Documentation/git-maintenance.txt b/Documentation/git-maintenance.txt index 7628a6d157..b5944b4c51 100644 --- a/Documentation/git-maintenance.txt +++ b/Documentation/git-maintenance.txt @@ -37,6 +37,23 @@ register:: `maintenance.<task>.schedule`. The tasks that are enabled are safe for running in the background without disrupting foreground processes. ++ +The `register` subcomand will also set the `maintenance.strategy` config +value to `incremental`, if this value is not previously set. The +`incremental` strategy uses the following schedule for each maintenance +task: ++ +-- +* `gc`: disabled. +* `commit-graph`: hourly. +* `prefetch`: hourly. +* `loose-objects`: daily. +* `incremental-repack`: daily. +-- ++ +`git maintenance register` will also disable foreground maintenance by +setting `maintenance.auto = false` in the current repository. This config +setting will remain after a `git maintenance unregister` command. run:: Run one or more maintenance tasks. If one or more `--task` options |