git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 0/2] rev-list --disk-usage example docs

From
Jeff King <peff@peff.net>
Date
Feb 17, 2021, 23:31 UTC
Message-ID
<YC2nOxPP3SAY2g1I@coredump.intra.peff.net>
In-Reply-To
<875z2ydd4l.fsf@evledraar.gmail.com>
On Thu, Feb 11, 2021 at 01:04:26PM +0100, Ævar Arnfjörð Bjarmason wrote:
Show 9 quoted lines
> > I think this is the "narrowly scoped" bit from Junio's response above.
> > It would be a bit weird to have an examples section for rev-list that
> > only mentions this rather obscure feature.
> 
> I don't think the lack of an EXAMPLES section or the relative obscurity
> of the switch should preclude us from adding useful documentation.
> 
> Yes it would feel a bit out of place, but we can always have a
> sub-section of EXAMPLES, and we've got to start somewhere.

Fair enough. Here are some patches (to go on top of jk/rev-list-disk-usage, though obviously the first one could be applied independently).

Show 5 quoted lines
> In this case I don't see why it couldn't be added to OPTIONS, we've got
> some very long discussion there already, and as long as there's a clear
> separation in prose from an initial brief discussion of the switch and
> further prose it won't be confusing for readers, they can just page past
> the details.

It's already big and scary enough that I prefer starting an EXAMPLES section. :)

By the way, there's one other finishing touch we might consider: enabling --use-bitmap-index automatically when bitmaps are present, for requests that produce the identical answer (so _not_ a regular traversal, because the output order and presence of pathnames are different there). I'd prefer to do that as a separate series, though, since there are multiple arguments that might benefit (like --count).

  [1/2]: docs/rev-list: add an examples section
  [2/2]: docs/rev-list: add some examples of --disk-usage
 Documentation/git-rev-list.txt | 93 ++++++++++++++++++++++++++++++++++
 1 file changed, 93 insertions(+)
-Peff
Previous: Junio C HamanoNext: Jeff King
Message 27 of 30 in “rev-list --disk-usage”
  1. 0/2 rev-list --disk-usageJeff King, Jan 27, 2021
  2. 1/2 t: add --no-tag option to test_commitJeff King, Jan 27, 2021
  3. Taylor BlauJan 27, 2021
  4. 2/2 rev-list: add --disk-usage option for calculating disk usageJeff King, Jan 27, 2021
  5. Taylor BlauJan 27, 2021
  6. Jeff KingJan 27, 2021
  7. Eric SunshineJan 27, 2021
  8. Jeff KingJan 27, 2021
  9. Kyle MeyerJan 27, 2021
  10. Jeff KingJan 27, 2021
  11. Taylor BlauJan 27, 2021
  12. rev-list --disk-usageJeff King, Feb 9, 2021
  13. 1/2 t: add --no-tag option to test_commitJeff King, Feb 9, 2021
  14. 2/2 rev-list: add --disk-usage option for calculating disk usageJeff King, Feb 9, 2021
  15. Jeff KingFeb 9, 2021
  16. Junio C HamanoFeb 9, 2021
  17. Jeff KingFeb 10, 2021
  18. Junio C HamanoFeb 10, 2021
  19. Taylor BlauFeb 10, 2021
  20. Jeff KingFeb 10, 2021
  21. Junio C HamanoFeb 10, 2021
  22. Jeff KingFeb 10, 2021
  23. Taylor BlauFeb 10, 2021
  24. Jeff KingFeb 11, 2021
  25. Ævar Arnfjörð BjarmasonFeb 11, 2021
  26. Junio C HamanoFeb 11, 2021
  27. 0/2 rev-list --disk-usage example docsJeff King, Feb 17, 2021
  28. 1/2 docs/rev-list: add an examples sectionJeff King, Feb 17, 2021
  29. 2/2 docs/rev-list: add some examples of --disk-usageJeff King, Feb 17, 2021
  30. Taylor BlauFeb 17, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.