Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions RelNotes/2.53.0.adoc
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
Git v2.53 Release Notes
=======================

UI, Workflows & Features
------------------------

* "git maintenance" command learned "is-needed" subcommand to tell if
it is necessary to perform various maintenance tasks.


Performance, Internal Implementation, Development Support etc.
--------------------------------------------------------------

Expand All @@ -10,3 +17,15 @@ Performance, Internal Implementation, Development Support etc.
* Some ref backend storage can hold not just the object name of an
annotated tag, but the object name of the object the tag points at.
The code to handle this information has been streamlined.

* As "git diff --quiet" only cares about the existence of any
changes, disable rename/copy detection to skip more expensive
processing whose result will be discarded anyway.


Fixes since v2.51
-----------------

* Ever since we added whitespace rules for this project, we misspelt
an entry, which has been corrected.
(merge 358e94dc70 jc/gitattributes-whitespace-no-indent-fix later to maint).
13 changes: 13 additions & 0 deletions git-maintenance.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ SYNOPSIS
'git maintenance' run [<options>]
'git maintenance' start [--scheduler=<scheduler>]
'git maintenance' (stop|register|unregister) [<options>]
'git maintenance' is-needed [<options>]


DESCRIPTION
Expand Down Expand Up @@ -84,6 +85,16 @@ The `unregister` subcommand will report an error if the current repository
is not already registered. Use the `--force` option to return success even
when the current repository is not registered.

is-needed::
Check whether maintenance needs to be run without actually running it.
Exits with a 0 status code if maintenance needs to be run, 1 otherwise.
Ideally used with the '--auto' flag.
+
If one or more `--task` options are specified, then those tasks are checked
in that order. Otherwise, the tasks are determined by which
`maintenance.<task>.enabled` config options are true. By default, only
`maintenance.gc.enabled` is true.

TASKS
-----

Expand Down Expand Up @@ -183,6 +194,8 @@ OPTIONS
in the `gc.auto` config setting, or when the number of pack-files
exceeds the `gc.autoPackLimit` config setting. Not compatible with
the `--schedule` option.
When combined with the `is-needed` subcommand, check if the required
thresholds are met without actually running maintenance.

--schedule::
When combined with the `run` subcommand, run maintenance tasks
Expand Down
21 changes: 18 additions & 3 deletions git-maintenance.html
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,8 @@ <h2 id="_synopsis">SYNOPSIS</h2>
<div class="verseblock">
<pre class="content"><em>git maintenance</em> run [&lt;options&gt;]
<em>git maintenance</em> start [--scheduler=&lt;scheduler&gt;]
<em>git maintenance</em> (stop|register|unregister) [&lt;options&gt;]</pre>
<em>git maintenance</em> (stop|register|unregister) [&lt;options&gt;]
<em>git maintenance</em> is-needed [&lt;options&gt;]</pre>
</div>
</div>
</div>
Expand Down Expand Up @@ -559,6 +560,18 @@ <h2 id="_subcommands">SUBCOMMANDS</h2>
when the current repository is not registered.</p>
</div>
</dd>
<dt class="hdlist1">is-needed</dt>
<dd>
<p>Check whether maintenance needs to be run without actually running it.
Exits with a 0 status code if maintenance needs to be run, 1 otherwise.
Ideally used with the <em>--auto</em> flag.</p>
<div class="paragraph">
<p>If one or more <code>--task</code> options are specified, then those tasks are checked
in that order. Otherwise, the tasks are determined by which
<code>maintenance.</code><em>&lt;task&gt;</em><code>.enabled</code> config options are true. By default, only
<code>maintenance.gc.enabled</code> is true.</p>
</div>
</dd>
</dl>
</div>
</div>
Expand Down Expand Up @@ -684,7 +697,9 @@ <h2 id="_options">OPTIONS</h2>
runs when the number of loose objects exceeds the number stored
in the <code>gc.auto</code> config setting, or when the number of pack-files
exceeds the <code>gc.autoPackLimit</code> config setting. Not compatible with
the <code>--schedule</code> option.</p>
the <code>--schedule</code> option.
When combined with the <code>is-needed</code> subcommand, check if the required
thresholds are met without actually running maintenance.</p>
</dd>
<dt class="hdlist1">--schedule</dt>
<dd>
Expand Down Expand Up @@ -1161,7 +1176,7 @@ <h2 id="_git">GIT</h2>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2025-06-20 18:10:42 -0700
Last updated 2025-11-21 14:01:32 -0800
</div>
</div>
</body>
Expand Down