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

Re: [PATCH 2/2] [GSOC] cat-file: merge two block into one

From
Jeff King <peff@peff.net>
Date
Jun 1, 2021, 15:55 UTC
Message-ID
<YLZYZS8jBiOJynbz@coredump.intra.peff.net>
In-Reply-To
<f02c1144d916bd36bd32069e439cfc08b2a7898a.1622558157.git.gitgitgadget@gmail.com>
On Tue, Jun 01, 2021 at 02:35:57PM +0000, ZheNing Hu via GitGitGadget wrote:
Show 5 quoted lines
> From: ZheNing Hu <adlternative@gmail.com>
> 
>  Because the two "if (opt->all_objects)" block
>  are redundant, merge them into one, to provide
>  better readability.
Funny indentation of the commit message. :)
I think this is worth doing, and I agree the end-result is easier to
read. Really minor nit, but I probably wouldn't have said "redundant"
here. The conditionals themselves are redundant, but not the blocks.
Maybe: There are two "if (opt->all_objects)" blocks next to each other;
merge them into one to provide better readability.

(not a huge deal, as I think seeing the patch helps explain what is going on. But again, just trying to offer polishing advice for future patches)

Previous: ZheNing Hu via GitGitGadgetNext: ZheNing Hu
Message 10 of 16 in “[GSOC] cat-file: fix --batch report changed-type bug”
  1. 0/2 [GSOC] cat-file: fix --batch report changed-type bugZheNing Hu via GitGitGadget, Jun 1, 2021
  2. 1/2 [GSOC] cat-file: fix --batch report changed-type bugZheNing Hu via GitGitGadget, Jun 1, 2021
  3. Jeff KingJun 1, 2021
  4. ZheNing HuJun 2, 2021
  5. Jeff KingJun 2, 2021
  6. ZheNing HuJun 3, 2021
  7. ZheNing HuJun 3, 2021
  8. Jeff KingJun 3, 2021
  9. 2/2 [GSOC] cat-file: merge two block into oneZheNing Hu via GitGitGadget, Jun 1, 2021
  10. Jeff KingJun 1, 2021
  11. ZheNing HuJun 2, 2021
  12. 0/2 [GSOC] cat-file: fix --batch report changed-type bugZheNing Hu via GitGitGadget, Jun 3, 2021
  13. 1/2 [GSOC] cat-file: handle trivial --batch format with --batch-all-objectsZheNing Hu via GitGitGadget, Jun 3, 2021
  14. 2/2 [GSOC] cat-file: merge two block into oneZheNing Hu via GitGitGadget, Jun 3, 2021
  15. Jeff KingJun 3, 2021
  16. Junio C HamanoJun 3, 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.