git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] doc/git-repack: small fixes for geometric repacks
@ 2023-10-16  7:19 Patrick Steinhardt
  2023-10-16  7:19 ` [PATCH 1/2] doc/git-repack: fix syntax for `-g` shorthand option Patrick Steinhardt
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Patrick Steinhardt @ 2023-10-16  7:19 UTC (permalink / raw)
  To: git; +Cc: Taylor Blau

[-- Attachment #1: Type: text/plain, Size: 406 bytes --]

Hi,

this small series addresses two issues in our documentation for the
git-repack(1) command that relate to geometric repacks.

Patrick

Patrick Steinhardt (2):
  doc/git-repack: fix syntax for `-g` shorthand option
  doc/git-repack: don't mention nonexistent "--unpacked" option

 Documentation/git-repack.txt | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

-- 
2.42.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/2] doc/git-repack: fix syntax for `-g` shorthand option
  2023-10-16  7:19 [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Patrick Steinhardt
@ 2023-10-16  7:19 ` Patrick Steinhardt
  2023-10-16  7:19 ` [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option Patrick Steinhardt
  2023-10-30 21:52 ` [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Taylor Blau
  2 siblings, 0 replies; 5+ messages in thread
From: Patrick Steinhardt @ 2023-10-16  7:19 UTC (permalink / raw)
  To: git; +Cc: Taylor Blau

[-- Attachment #1: Type: text/plain, Size: 981 bytes --]

The `-g` switch is a shorthand for `--geometric=` and allows the user to
specify the geometric. The documentation is wrong though and indicates
that the syntax for the shorthand is `-g=<factor>`. In fact though, the
option must be specified without the equals sign via `-g<factor>`.

Fix the syntax accordingly.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
---
 Documentation/git-repack.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/git-repack.txt b/Documentation/git-repack.txt
index 8545a32667..dfd2a59c50 100644
--- a/Documentation/git-repack.txt
+++ b/Documentation/git-repack.txt
@@ -209,7 +209,7 @@ depth is 4095.
 	Pass the `--delta-islands` option to `git-pack-objects`, see
 	linkgit:git-pack-objects[1].
 
--g=<factor>::
+-g<factor>::
 --geometric=<factor>::
 	Arrange resulting pack structure so that each successive pack
 	contains at least `<factor>` times the number of objects as the
-- 
2.42.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option
  2023-10-16  7:19 [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Patrick Steinhardt
  2023-10-16  7:19 ` [PATCH 1/2] doc/git-repack: fix syntax for `-g` shorthand option Patrick Steinhardt
@ 2023-10-16  7:19 ` Patrick Steinhardt
  2023-10-30 21:51   ` Taylor Blau
  2023-10-30 21:52 ` [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Taylor Blau
  2 siblings, 1 reply; 5+ messages in thread
From: Patrick Steinhardt @ 2023-10-16  7:19 UTC (permalink / raw)
  To: git; +Cc: Taylor Blau

[-- Attachment #1: Type: text/plain, Size: 1491 bytes --]

The documentation for geometric repacking mentions a "--unpacked" option
that supposedly changes how loose objects are rolled up. This option has
never existed, and the implied behaviour, namely to include all unpacked
objects into the resulting packfile, is in fact the default behaviour.

Correct the documentation to not mention this option.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
---
 Documentation/git-repack.txt | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/Documentation/git-repack.txt b/Documentation/git-repack.txt
index dfd2a59c50..d61078b697 100644
--- a/Documentation/git-repack.txt
+++ b/Documentation/git-repack.txt
@@ -226,11 +226,8 @@ uniquely by the set of packs being "rolled-up"; in other words, the
 packs determined to need to be combined in order to restore a geometric
 progression.
 +
-When `--unpacked` is specified, loose objects are implicitly included in
-this "roll-up", without respect to their reachability. This is subject
-to change in the future. This option (implying a drastically different
-repack mode) is not guaranteed to work with all other combinations of
-option to `git repack`.
+Loose objects are implicitly included in this "roll-up", without respect to
+their reachability. This is subject to change in the future.
 +
 When writing a multi-pack bitmap, `git repack` selects the largest resulting
 pack as the preferred pack for object selection by the MIDX (see
-- 
2.42.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option
  2023-10-16  7:19 ` [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option Patrick Steinhardt
@ 2023-10-30 21:51   ` Taylor Blau
  0 siblings, 0 replies; 5+ messages in thread
From: Taylor Blau @ 2023-10-30 21:51 UTC (permalink / raw)
  To: Patrick Steinhardt; +Cc: git

On Mon, Oct 16, 2023 at 09:19:56AM +0200, Patrick Steinhardt wrote:
> The documentation for geometric repacking mentions a "--unpacked" option
> that supposedly changes how loose objects are rolled up. This option has
> never existed, and the implied behaviour, namely to include all unpacked
> objects into the resulting packfile, is in fact the default behaviour.
>
> Correct the documentation to not mention this option.
>
> Signed-off-by: Patrick Steinhardt <ps@pks.im>
> ---
>  Documentation/git-repack.txt | 7 ++-----
>  1 file changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/Documentation/git-repack.txt b/Documentation/git-repack.txt
> index dfd2a59c50..d61078b697 100644
> --- a/Documentation/git-repack.txt
> +++ b/Documentation/git-repack.txt
> @@ -226,11 +226,8 @@ uniquely by the set of packs being "rolled-up"; in other words, the
>  packs determined to need to be combined in order to restore a geometric
>  progression.
>  +
> -When `--unpacked` is specified, loose objects are implicitly included in
> -this "roll-up", without respect to their reachability. This is subject
> -to change in the future. This option (implying a drastically different
> -repack mode) is not guaranteed to work with all other combinations of
> -option to `git repack`.
> +Loose objects are implicitly included in this "roll-up", without respect to
> +their reachability. This is subject to change in the future.
>  +

Oops. This refers to the "--unpacked" option that pack-objects takes,
not repack. I agree that mentioning "--unpacked" is too low-level a
detail for this user-facing documentation, so even something like:

    When `repack` passes `--unpacked` down to `pack-objects` (which is
    the default) ...

would be too much detail for this man page.

I am very happy with the patch here as an alternative.

Thanks,
Taylor

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/2] doc/git-repack: small fixes for geometric repacks
  2023-10-16  7:19 [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Patrick Steinhardt
  2023-10-16  7:19 ` [PATCH 1/2] doc/git-repack: fix syntax for `-g` shorthand option Patrick Steinhardt
  2023-10-16  7:19 ` [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option Patrick Steinhardt
@ 2023-10-30 21:52 ` Taylor Blau
  2 siblings, 0 replies; 5+ messages in thread
From: Taylor Blau @ 2023-10-30 21:52 UTC (permalink / raw)
  To: Patrick Steinhardt; +Cc: git

On Mon, Oct 16, 2023 at 09:19:46AM +0200, Patrick Steinhardt wrote:
> Patrick Steinhardt (2):
>   doc/git-repack: fix syntax for `-g` shorthand option
>   doc/git-repack: don't mention nonexistent "--unpacked" option
>
>  Documentation/git-repack.txt | 9 +++------
>  1 file changed, 3 insertions(+), 6 deletions(-)

Sorry that this one fell off of my queue. These are both looking good to
me, thanks for finding and fixing them!

Thanks,
Taylor

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-10-30 21:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-16  7:19 [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Patrick Steinhardt
2023-10-16  7:19 ` [PATCH 1/2] doc/git-repack: fix syntax for `-g` shorthand option Patrick Steinhardt
2023-10-16  7:19 ` [PATCH 2/2] doc/git-repack: don't mention nonexistent "--unpacked" option Patrick Steinhardt
2023-10-30 21:51   ` Taylor Blau
2023-10-30 21:52 ` [PATCH 0/2] doc/git-repack: small fixes for geometric repacks Taylor Blau

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).